Skip to content

feat: new release to align with op specs v1.3.2#8

Open
adrianboros wants to merge 12 commits into
mainfrom
adrian/php-1-release-op-v1.3.2
Open

feat: new release to align with op specs v1.3.2#8
adrianboros wants to merge 12 commits into
mainfrom
adrian/php-1-release-op-v1.3.2

Conversation

@adrianboros

Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the SDK to align with Open Payments specifications v1.3.2, including OpenAPI spec sync, new resource capabilities, and PHP 8.3 model/DTO immutability changes.

Changes:

  • Add GET /outgoing-payment-grant support via OutgoingPaymentService::getGrant() plus OutgoingPaymentGrant model and typed exceptions.
  • Deprecate WalletAddressService::getDIDDocument() (now calls /did.json and triggers E_USER_DEPRECATED) and update related tests/docs.
  • Sync bundled OpenAPI specs to v1.3.2 and modernize DTO/Model code (strict types + readonly).

Reviewed changes

Copilot reviewed 62 out of 62 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
tests/Services/WalletAddressServiceTest.php Updates DID document URL expectation and adds deprecation-notice coverage.
tests/Services/OutgoingPaymentServiceTest.php Adds test coverage for the new outgoing payment grant endpoint/model and error cases.
README.md Documents initializing the OpenAPI specs submodule; fixes a typo.
lib/Traits/HasErrorResponse.php Introduces a trait to attach parsed error models to exceptions.
lib/Services/WalletAddressService.php Deprecates getDIDDocument(), triggers a deprecation notice, and updates path to /did.json.
lib/Services/OutgoingPaymentService.php Adds getGrant() to fetch spent amounts for the current outgoing payment grant.
lib/OpenApi/SpecVersion.php Adds a constant tracking the upstream spec version (v1.3.2).
lib/OpenApi/Specs/resource-server.yaml Adds OpenAPI path definition for GET /outgoing-payment-grant.
lib/OpenApi/Specs/auth-server.yaml Updates auth server OpenAPI to v1.3.2 with new schemas and structured error responses.
lib/Models/WalletAddress.php Marks properties readonly and adds strict types.
lib/Models/SimpleAccessToken.php Marks properties readonly and adds strict types.
lib/Models/Quote.php Marks properties readonly and adds strict types.
lib/Models/PublicIncomingPayment.php Marks properties readonly and adds strict types.
lib/Models/PendingGrantInteract.php Marks properties readonly and adds strict types.
lib/Models/PendingGrantContinue.php Marks properties readonly and adds strict types.
lib/Models/PendingGrant.php Marks properties readonly and adds strict types.
lib/Models/OutgoingPaymentGrant.php Adds model representing grant spent amounts (nullable Amount fields).
lib/Models/OutgoingPayment.php Marks properties readonly and adds strict types.
lib/Models/JsonWebKeySet.php Marks properties readonly and adds strict types.
lib/Models/JsonWebKey.php Makes optional fields nullable/always initialized; simplifies toArray() filtering.
lib/Models/IncomingPayment.php Marks properties readonly and adds strict types.
lib/Models/IlpPaymentMethod.php Marks properties readonly and adds strict types.
lib/Models/GrantError.php Adds structured auth-server error model parsing error.code/error.description.
lib/Models/GrantContinue.php Marks properties readonly and adds strict types.
lib/Models/Grant.php Marks properties readonly and adds strict types.
lib/Models/ErrorResponse.php Adds generic resource-server error model (error, optional message).
lib/Models/Amount.php Marks properties readonly, adds strict types, and updates doc text.
lib/Models/AccessToken.php Marks properties readonly and adds strict types.
lib/Exceptions/UnauthorizedException.php Adds HasErrorResponse trait to carry parsed error models.
lib/Exceptions/GetOutgoingPaymentGrantUnauthorizedException.php Adds typed unauthorized exception for getGrant().
lib/Exceptions/GetOutgoingPaymentGrantForbiddenException.php Adds typed forbidden exception for getGrant().
lib/Exceptions/ForbiddenException.php Adds HasErrorResponse trait to carry parsed error models.
lib/Exceptions/ApiException.php Adds HasErrorResponse trait to carry parsed error models.
lib/Enums/GrantErrorCode.php Adds enum for structured auth-server error codes.
lib/DTO/UnauthenticatedResourceRequestArgs.php Marks DTO properties readonly and adds strict types.
lib/DTO/ResourceRequest/QuoteRequest.php Adds strict types + typed const; makes fields readonly.
lib/DTO/ResourceRequest/QuoteAccess.php Adds strict types + typed const; makes fields readonly.
lib/DTO/ResourceRequest/OutgoingPaymentRequest.php Adds strict types + typed const; makes fields readonly.
lib/DTO/ResourceRequest/OutgoingPaymentAccess.php Adds strict types + typed const; makes fields readonly.
lib/DTO/ResourceRequest/Limits.php Adds strict types; makes fields readonly.
lib/DTO/ResourceRequest/IncomingPaymentRequest.php Adds strict types + typed const; makes fields readonly and simplifies identifier handling.
lib/DTO/ResourceRequest/IncomingPaymentAccess.php Adds strict types + typed const; makes fields readonly.
lib/DTO/PendingGrantInteraction.php Adds strict types; makes fields readonly.
lib/DTO/PendingGrantContinuation.php Adds strict types; makes fields readonly.
lib/DTO/PendingGrantAccessToken.php Adds strict types; makes fields readonly.
lib/DTO/PendingGrant.php Adds strict types; makes fields readonly.
lib/DTO/NonInteractiveGrantRequest.php Adds strict types; makes fields readonly.
lib/DTO/GrantRequest.php Adds strict types; makes fields readonly.
lib/DTO/GrantOrTokenRequestArgs.php Adds strict types; makes fields readonly.
lib/DTO/GrantInteractionFinish.php Adds strict types; makes fields readonly (except method).
lib/DTO/GrantInteraction.php Adds strict types; makes finish readonly/nullable.
lib/DTO/GrantContinuationRequest.php Adds strict types; makes fields readonly.
lib/DTO/Grant.php Adds strict types; makes fields readonly.
lib/DTO/CollectionRequestArgs.php Adds strict types; makes fields readonly.
lib/DTO/AuthenticatedRequestArgs.php Adds strict types; makes fields readonly.
lib/DTO/AccessToken.php Adds strict types; makes fields readonly.
lib/Contracts/WalletAddressRoutes.php Documents deprecation of getDIDDocument() at the contract level.
lib/Contracts/OutgoingPaymentRoutes.php Adds getGrant() route to the outgoing payment contract.
lib/Config/Config.php Exposes useHttp via a new getter.
CHANGELOG.md Adds v1.1.0 changelog entries for spec sync, deprecation, and new endpoint/models.
.gitmodules Adds open-payments-specifications submodule configuration.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread lib/Services/WalletAddressService.php
Comment thread tests/Services/WalletAddressServiceTest.php
Comment thread lib/Services/OutgoingPaymentService.php Outdated
Comment thread CHANGELOG.md Outdated
Comment thread lib/DTO/GrantInteraction.php
Comment thread tests/Services/WalletAddressServiceTest.php
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants