Skip to content

Add GET /outgoing-payment-grant route to resource server #15

@mkurapov

Description

@mkurapov

We want to be able to provide the client with information about a balance (or how much was spent already) under an outgoing payment grant. This would be a useful feature for applications/clients which create multiple outgoing payments under a single grant: they would want to provide users information about how much can still be taken from their account without additional interaction/approval.

Route

GET /outgoing-payment-grant

Description

Returns the spent amounts for the current grant corresponding to the presented GNAP access token. If a grant was created with an interval (recurring), the amounts returned are for the current interval.

Response

{
    "spentReceiveAmount": { value, assetCode, assetScale }
    "spentDebitAmount": { value, assetCode, assetScale }
}

Errors

  • 403 - Forbidden (if token presented does not match with a grant containing outgoing-payment type with create access)

Tasks

  • Add route to resource server, do a minor update of specs to 1.2.0

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

Status

Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions