--- swagger: "2.0" info: title: Rewards API description: Swagger specification for Rewards API version: 1.0.6 x-ibm-name: rewards-api name: "" basePath: /open-banking schemes: - https produces: - application/json - cc309236 paths: /reward-redemption: post: tags: - Reward Redemption summary: Reward Redemption Request description: Reward Redemption Request operationId: CreateRewardRedemption consumes: - application/json produces: - application/json parameters: - name: x-idempotency-key in: header description: Every request will be processed only once per x-idempotency-key. The Idempotency Key will be valid for 24 hours. required: true type: string maxLength: 40 - in: header name: x-fapi-financial-id type: string required: true description: The unique id of the ASPSP to which the request is issued. The unique id will be issued by OB. - in: header name: x-fapi-customer-last-logged-time type: string required: false description: The time when the PSU last logged in with the TPP. - in: header name: x-fapi-customer-ip-address type: string required: false description: The PSU's IP address if the PSU is currently logged in with the TPP. - in: header name: x-fapi-interaction-id type: string required: false description: An RFC4122 UID used as a correlation id. - in: header name: authorization type: string required: true description: An Authorisation Token as per https://tools.ietf.org/html/rfc6750 - in: header name: x-jws-signature type: string required: true description: Header containing a detached JWS signature of the body of the payload. - name: body in: body description: Reward Redemption Request Body required: true schema: title: Reward Redemption POST request description: Allows Reward Redemption type: object properties: Data: description: "" title: Reward Redemption type: object properties: RedemptionRequestId: description: 'OB: Unique identification as assigned by the ASPSP to uniquely identify the reward redemption request setup resource.' type: string minLength: 1 maxLength: 128 Initiation: description: Setup Information type: object properties: InstructionIdentification: description: 'Unique identification as assigned by an instructing party for an instructed party to unambiguously identify the instruction. Usage: the instruction identification is a point to point reference that can be used between the instructing party and the instructed party to refer to the individual instruction. It can be included in several messages related to the instruction.' type: string minLength: 1 maxLength: 35 EndToEndIdentification: description: 'Unique identification assigned by the initiating party to unambiguously identify the transaction. This identification is passed on, unchanged, throughout the entire end-to-end chain. Usage: The end-to-end identification can be used for reconciliation or to link tasks relating to the transaction. It can be included in several messages related to the transaction. OB: The Faster Payments Scheme can only access 31 characters for the EndToEndIdentification field.' type: string minLength: 1 maxLength: 35 InstructedAmount: description: 'Amount of points(or eq money) to be moved between the debtor and creditor, before deduction of charges, expressed in the currency as ordered by the initiating party. Usage: This points has to be transported unchanged through the transaction chain.' type: object properties: Amount: type: string Currency: description: A code allocated to a currency by a Maintenance Agency (Bank). type: string required: - Amount - Currency additionalProperties: false RedemptionInformation: description: Information supplied to enable the matching of an entry with the items that the transfer is intended to settle, such as commercial invoices in an accounts' receivable system. title: Remittance Information type: object properties: Unstructured: description: Information supplied to enable the matching/reconciliation of an entry with the items that the reward redemption is intended to settle, such as commercial invoices in an accounts' receivable system, in an unstructured form. type: string minLength: 1 maxLength: 140 Reference: description: 'Unique reference, as assigned by the creditor, to unambiguously refer to the reward redemption transaction. Usage: If available, the initiating party should provide this reference in the structured remittance information, to enable reconciliation by the creditor upon receipt of the amount of money. If the business context requires the use of a creditor reference or a payment remit identification, and only one identifier can be passed through the end-to-end chain, the creditor''s reference or payment remittance identification should be quoted in the end-to-end transaction identification. OB: The Faster Payments Scheme can only accept 18 characters for the ReferenceInformation field - which is where this ISO field will be mapped.' type: string minLength: 1 maxLength: 35 additionalProperties: false required: - InstructionIdentification - EndToEndIdentification - InstructedAmount additionalProperties: false required: - RedemptionRequestId - Initiation additionalProperties: false required: - Data additionalProperties: false responses: 201: description: Reward Redemption resource successfully created schema: title: reward redemption POST response type: object properties: Data: description: reward redemption response title: Reward redepmtion response type: object properties: RedemptionRequestId: description: 'OB: Unique identification as assigned by the ASPSP to uniquely identify the reward request setup resource.' type: string minLength: 1 maxLength: 128 RewardRedemptionId: description: 'OB: Unique identification as assigned by the ASPSP to uniquely identify the reward redemption resource.' type: string minLength: 1 maxLength: 128 Status: description: Specifies the status of the reward redemption resource. title: Reward redemption Status Code type: string enum: - AcceptedSettlementCompleted - AcceptedSettlementInProcess - Pending - Rejected CreationDateTime: description: Date and time at which the resource was created. type: string format: date-time required: - RedemptionRequestId - RewardRedemptionId - Status - CreationDateTime additionalProperties: false Links: type: object description: Link URIs relevant to the payload properties: self: type: string format: uri first: type: string format: uri prev: type: string format: uri next: type: string format: uri last: type: string format: uri additionalProperties: false required: - self Meta: type: object description: Meta Data Relevant to the payload properties: total-pages: type: integer format: int32 additionalProperties: false required: - Data - Links - Meta additionalProperties: false headers: x-jws-signature: type: string description: Header containing a detached JWS signature of the body of the payload. x-fapi-interaction-id: type: string description: An RFC4122 UID used as a correlation id. 400: description: Bad Request 401: description: Unauthorized 403: description: Forbidden 429: description: Too Many Requests 500: description: Internal Server Error security: - RedemptionsPSUOAuth2Security: - redemptions - openid X-IBM-Client-Secret: [] X-IBM-Client-Id: [] /reward-reversal: post: tags: - Reward Redemption summary: Reward Redemption Reversal Request description: Reward Redemption Reversal Request operationId: RewardReversal consumes: - application/json produces: - application/json parameters: - name: x-idempotency-key in: header description: Every request will be processed only once per x-idempotency-key. The Idempotency Key will be valid for 24 hours. required: true type: string maxLength: 40 - in: header name: x-fapi-financial-id type: string required: true description: The unique id of the ASPSP to which the request is issued. The unique id will be issued by OB. - in: header name: x-fapi-customer-last-logged-time type: string required: false description: The time when the PSU last logged in with the TPP. - in: header name: x-fapi-customer-ip-address type: string required: false description: The PSU's IP address if the PSU is currently logged in with the TPP. - in: header name: x-fapi-interaction-id type: string required: false description: An RFC4122 UID used as a correlation id. - in: header name: authorization type: string required: true description: An Authorisation Token as per https://tools.ietf.org/html/rfc6750 - in: header name: x-jws-signature type: string required: false description: Header containing a detached JWS signature of the body of the payload. - name: body in: body description: Reward Redemption Request Body required: true schema: title: Reward Redemption Reverse request description: Allows Reversal for Reward Redemption type: object properties: PurchaseOrderNumber: description: A unique identifier used to identify the reward redemption resource. type: string minLength: 1 maxLength: 128 ReversalReason: description: Reason for reversal of reward redemption. type: string required: - ReversalReason - PurchaseOrderNumber additionalProperties: false responses: 200: description: Reward Reversal successfully done schema: title: Reward Reversal response type: object properties: PurchaseOrderNumber: description: A unique identifier used to identify the reward redemption resource. type: string ReversalReason: description: Reason for reversal of reward redemption. type: string 400: description: Bad Request 401: description: Unauthorized 403: description: Forbidden 429: description: Too Many Requests 500: description: Internal Server Error security: - X-IBM-Client-Id: [] X-IBM-Client-Secret: [] TPPOAuth2Security: - tpp_client_credential /rewards/{RewardsAccountId}/balances: get: tags: - Read Rewards summary: Get Rewards Account Balances description: Get Rewards Balances related to an account operationId: GetRewardsAccountBalances produces: - application/json parameters: - name: RewardsAccountId in: path description: A unique identifier used to identify the rewards account resource. required: true type: string - in: header name: x-fapi-financial-id type: string required: true description: The unique id of the ASPSP to which the request is issued. The unique id will be issued by OB. - in: header name: x-fapi-customer-last-logged-time type: string required: false description: The time when the PSU last logged in with the TPP. - in: header name: x-fapi-customer-ip-address type: string required: false description: The PSU's IP address if the PSU is currently logged in with the TPP. - in: header name: x-fapi-interaction-id type: string required: false description: An RFC4122 UID used as a correlation id. - in: header name: authorization type: string required: true description: An Authorisation Token as per https://tools.ietf.org/html/rfc6750 responses: 200: description: Reward Account Balance successfully retrieved schema: title: Reward Account Balance GET response type: object properties: Data: title: Balance type: array items: type: object title: Balance description: Balance properties: RewardsAccountId: description: A unique and immutable identifier used to identify the account resource. This identifier has no meaning to the account owner. type: string minLength: 1 maxLength: 40 Amount: description: Amount of money of the cash balance. type: object properties: Amount: type: string pattern: ^-?\d{1,13}\.\d{1,5}$ Currency: description: A code allocated to a currency by bank type: string required: - Amount - Currency additionalProperties: false DateTime: description: Indicates the date (and time) of the balance. type: string format: date-time additionalProperties: false required: - RewardsAccountId - Amount - DateTime minItems: 1 Links: title: Links type: object description: Links relevant to the payload properties: self: type: string format: uri first: type: string format: uri prev: type: string format: uri next: type: string format: uri last: type: string format: uri additionalProperties: false required: - self Meta: title: Meta Data type: object description: Meta Data relevant to the payload properties: total-pages: type: integer format: int32 additionalProperties: false additionalProperties: false required: - Data - Links - Meta headers: x-jws-signature: type: string description: Header containing a detached JWS signature of the body of the payload. x-fapi-interaction-id: type: string description: An RFC4122 UID used as a correlation id. 400: description: Bad Request 401: description: Unauthorized 403: description: Forbidden 429: description: Too Many Requests 500: description: Internal Server Error security: - PSUOAuth2Security: - rewards - openid X-IBM-Client-Secret: [] X-IBM-Client-Id: [] /rewards/accounts: get: tags: - Read Rewards summary: Get Rewards list of accounts description: Get Rewards list of accounts for a customer operationId: GetRewardAccounts produces: - application/json parameters: - in: header name: x-fapi-financial-id type: string required: true description: The unique id of the ASPSP to which the request is issued. The unique id will be issued by OB. - in: header name: x-fapi-customer-last-logged-time type: string required: false description: The time when the PSU last logged in with the TPP. - in: header name: x-fapi-customer-ip-address type: string required: false description: The PSU's IP address if the PSU is currently logged in with the TPP. - in: header name: x-fapi-interaction-id type: string required: false description: An RFC4122 UID used as a correlation id. - in: header name: authorization type: string required: true description: An Authorisation Token as per https://tools.ietf.org/html/rfc6750 responses: 200: description: Accounts successfully retrieved schema: title: Account GET response type: object properties: Data: title: Reward Accounts type: array items: type: object title: Account description: Account properties: RewardsAccountId: description: A unique and immutable identifier used to identify the account resource. This identifier has no meaning to the account owner. type: string minLength: 1 maxLength: 40 RewardsAccountName: description: Account type type: string minLength: 1 maxLength: 40 Amount: description: Amount of reward points type: object properties: Amount: type: string Currency: description: A code allocated to a currency by bank type: string required: - Amount - Currency additionalProperties: false additionalProperties: false required: - RewardsAccountId - Amount Links: title: Links type: object description: Links relevant to the payload properties: self: type: string format: uri first: type: string format: uri prev: type: string format: uri next: type: string format: uri last: type: string format: uri additionalProperties: false required: - self Meta: title: Meta Data type: object description: Meta Data relevant to the payload properties: total-pages: type: integer format: int32 additionalProperties: false additionalProperties: false required: - Data - Links - Meta headers: x-jws-signature: type: string description: Header containing a detached JWS signature of the body of the payload. x-fapi-interaction-id: type: string description: An RFC4122 UID used as a correlation id. 400: description: Bad Request 401: description: Unauthorized 403: description: Forbidden 429: description: Too Many Requests 500: description: Internal Server Error security: - PSUOAuth2Security: - rewards - openid X-IBM-Client-Secret: [] X-IBM-Client-Id: [] securityDefinitions: TPPOAuth2Security: type: oauth2 flow: application tokenUrl: https://api.nedbank.co.za/apimarket/sandbox/nboauth/oauth20/token scopes: tpp_client_credential: TPP Client Credential Scope description: TPP client credential authorisation flow with the ASPSP x-tokenIntrospect: url: https://api-market.nedsecure.nednet.co.za/mga/sps/oauth/oauth20/introspect PSUOAuth2Security: type: oauth2 description: OAuth flow, it is required when the PSU needs to perform SCA with the ASPSP when a TPP wants to access an ASPSP resource owned by the PSU flow: accessCode scopes: rewards: "" openid: "" authorizationUrl: https://api.nedbank.co.za/apimarket/sandbox/oauth/oauth20/authorize tokenUrl: https://api.nedbank.co.za/apimarket/sandbox/nboauth/oauth20/token x-tokenIntrospect: url: https://api-market.nedsecure.nednet.co.za/mga/sps/oauth/oauth20/introspect RedemptionsPSUOAuth2Security: type: oauth2 description: OAuth flow, it is required when the PSU needs to perform SCA with the ASPSP when a TPP wants to access an ASPSP resource owned by the PSU flow: accessCode scopes: redemptions: "" openid: cc309236 authorizationUrl: https://api.nedbank.co.za/apimarket/sandbox/oauth/oauth20/authorize tokenUrl: https://api.nedbank.co.za/apimarket/sandbox/nboauth/oauth20/token x-tokenIntrospect: url: https://api-market.nedsecure.nednet.co.za/mga/sps/oauth/oauth20/introspect x-scopeValidate: tls-profile: cc309236 X-IBM-Client-Secret: type: apiKey description: "" in: header name: X-IBM-Client-Secret X-IBM-Client-Id: type: apiKey description: "" in: header name: X-IBM-Client-Id responses: 400ErrorResponse: description: Bad Request 401ErrorResponse: description: Unauthorized 403ErrorResponse: description: Forbidden 429ErrorResponse: description: Too Many Requests 500ErrorResponse: description: Internal Server Error x-ibm-configuration: enforced: true testable: true phase: realized security: - PSUOAuth2Security: - openid - rewards X-IBM-Client-Secret: [] X-IBM-Client-Id: [] x-ibm-endpoints: - endpointUrl: https://api.nedbank.co.za/apimarket/sandbox type: - production ...