--- swagger: "2.0" info: x-ibm-name: partner-authentication-api title: Partner Authentication API version: 1.4.0 contact: name: API developer email: apideveloper@rakbank.ae description: Server-side client applications of Partners should use this API to generate an Access Token for a specific set of scopes. Any metadata that needs to be included into the access token can be provided in the "oauth_metadata". Certain scopes may require specific metadata fields. Wherever applicable, the API specification will have the details. name: "" schemes: - https host: sandboxapi.rakbank.ae basePath: /v1/partner_auth paths: /token: post: responses: 200: description: 200 OK schema: $ref: '#/definitions/access_token_response' 401: description: Unauthorized schema: $ref: '#/definitions/error_response' 403: description: Forbidden schema: $ref: '#/definitions/error_response' parameters: - name: access_token_request required: true in: body schema: $ref: '#/definitions/access_token_request' description: Access Token Request summary: Request Access Tokens description: This endpoint allows requesting an access token operationId: GenerateToken parameters: - $ref: '#/parameters/MsgId' consumes: - application/json produces: - application/json securityDefinitions: clientSecretHeader: type: apiKey description: "" in: header name: X-IBM-Client-Secret clientIdHeader: type: apiKey in: header name: X-IBM-Client-Id security: - clientIdHeader: [] clientSecretHeader: [] x-ibm-configuration: testable: true enforced: true phase: realized definitions: access_token_request: description: request for access token type: object properties: grant_type: type: string enum: - client_credentials description: Type of grant. Valid values are "client_credentials" scope: type: string minLength: 1 maxLength: 500 description: Scope being requested oauth_metadata: description: "" $ref: '#/definitions/oauth_metadata' required: - grant_type - scope additionalProperties: false access_token_response: type: object additionalProperties: true required: - token_type - access_token - expires_in - scope properties: token_type: enum: - bearer description: The token type example: bearer access_token: type: string minLength: 1 maxLength: 5000 description: The access token expires_in: type: integer description: The expiry time in seconds scope: type: string minLength: 1 maxLength: 500 description: Scope that was requested error_response: properties: status: type: string description: HTTP Status response_code: type: string description: API specific error code property: type: string response_message: type: string description: brief type of the error example: "" description: type: string description: detailed description of the error additionalProperties: false required: - response_code - status - response_message description: Response in case of error oauth_metadata: properties: account_id: type: string description: Account ID against which access_token is requested. example: 0188000049916 emirates_id: type: string description: Emirates ID against which access_token is requested. example: "500000000006190" additionalProperties: true description: This will contain the metadata to be included in the oauth token. Certain scopes may require specific metadata fields. Wherever applicable, the API specification will have the details. parameters: MsgId: name: MsgId type: string required: true in: header description: MsgId tags: [] x-ibm-endpoints: - endpointUrl: https://sandboxapi.rakbank.ae/sb/api type: - production - development ...