[PR #61] [MERGED] Add a Request::getLastResponse() method #240

Closed
opened 2026-02-27 19:26:46 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/jwilsson/spotify-web-api-php/pull/61
Author: @jwilsson
Created: 12/11/2016
Status: Merged
Merged: 12/11/2016
Merged by: @jwilsson

Base: masterHead: request-last-response


📝 Commits (3)

  • 6049d09 Expose lastResponse in Request
  • 1ea0c45 Add a SpotifyWebAPI::getRequest() method
  • cc42b8c Add docs on error handling

📊 Changes

6 files changed (+90 additions, -7 deletions)

View changed files

docs/examples/error-handling.md (+33 -0)
📝 docs/examples/index.md (+1 -0)
📝 src/Request.php (+30 -7)
📝 src/SpotifyWebAPI.php (+10 -0)
📝 tests/RequestTest.php (+9 -0)
📝 tests/SpotifyWebAPITest.php (+7 -0)

📄 Description

Since SpotifyWebAPI::getLastResponse() isn't available when exceptions are thrown (as noted in #60) I've added a new getLastResponse() method to Request as well which will always be populated will the full response.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/jwilsson/spotify-web-api-php/pull/61 **Author:** [@jwilsson](https://github.com/jwilsson) **Created:** 12/11/2016 **Status:** ✅ Merged **Merged:** 12/11/2016 **Merged by:** [@jwilsson](https://github.com/jwilsson) **Base:** `master` ← **Head:** `request-last-response` --- ### 📝 Commits (3) - [`6049d09`](https://github.com/jwilsson/spotify-web-api-php/commit/6049d0903d2f70b59e9ac8f4dd118a4a2a2e011f) Expose lastResponse in Request - [`1ea0c45`](https://github.com/jwilsson/spotify-web-api-php/commit/1ea0c45665427e54faf74bcdb7fa5fae52f76660) Add a SpotifyWebAPI::getRequest() method - [`cc42b8c`](https://github.com/jwilsson/spotify-web-api-php/commit/cc42b8c76016f5deeb5bf6bb0007f3b55353c4f1) Add docs on error handling ### 📊 Changes **6 files changed** (+90 additions, -7 deletions) <details> <summary>View changed files</summary> ➕ `docs/examples/error-handling.md` (+33 -0) 📝 `docs/examples/index.md` (+1 -0) 📝 `src/Request.php` (+30 -7) 📝 `src/SpotifyWebAPI.php` (+10 -0) 📝 `tests/RequestTest.php` (+9 -0) 📝 `tests/SpotifyWebAPITest.php` (+7 -0) </details> ### 📄 Description Since `SpotifyWebAPI::getLastResponse()` isn't available when exceptions are thrown (as noted in #60) I've added a new `getLastResponse()` method to `Request` as well which will always be populated will the full response. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 19:26:46 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotify-web-api-php#240
No description provided.