openapi: 3.1.0 info: title: Tango RaaS Accounts Orders API description: The Tango Rewards-as-a-Service (RaaS) API v2 enables companies to automate digital reward and incentive delivery. Access a global catalog of 3,100+ digital gift cards, prepaid cards, and charitable donations. Manage customer accounts, fund balances, place orders, configure email templates, and receive real-time webhook notifications. version: '2.0' termsOfService: https://www.tangocard.com/terms-of-service/ contact: name: Tango Developer Support email: devsupport@tangocard.com url: https://developers.tangocard.com/ license: name: Proprietary url: https://www.tangocard.com/terms-of-service/ servers: - url: https://api.tangocard.com/raas/v2 description: Production - url: https://integration-api.tangocard.com/raas/v2 description: Sandbox security: - basicAuth: [] tags: - name: Orders description: Place and manage reward orders paths: /orders: get: operationId: listOrders summary: List Orders description: Retrieve a list of orders placed by the account. tags: - Orders parameters: - name: startDate in: query schema: type: string format: date-time description: Filter orders from this date - name: endDate in: query schema: type: string format: date-time description: Filter orders up to this date - name: elements in: query schema: type: integer default: 100 description: Number of results per page - name: offset in: query schema: type: integer default: 0 description: Pagination offset responses: '200': description: List of orders content: application/json: schema: type: object properties: orders: type: array items: $ref: '#/components/schemas/Order' post: operationId: createOrder summary: Create Order description: Place a new reward order. This deducts the reward value from the specified account balance and delivers the digital reward to the recipient. tags: - Orders requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateOrderRequest' responses: '201': description: Order placed successfully content: application/json: schema: $ref: '#/components/schemas/Order' '400': $ref: '#/components/responses/BadRequest' /orders/{referenceOrderID}: get: operationId: getOrder summary: Get Order description: Retrieve details of a specific order by reference ID. tags: - Orders parameters: - $ref: '#/components/parameters/referenceOrderID' responses: '200': description: Order details content: application/json: schema: $ref: '#/components/schemas/Order' /orders/{referenceOrderID}/resends: post: operationId: resendOrder summary: Resend Order description: Resend a fulfilled order to the recipient. tags: - Orders parameters: - $ref: '#/components/parameters/referenceOrderID' responses: '200': description: Order resent content: application/json: schema: $ref: '#/components/schemas/Order' components: schemas: LineItem: type: object properties: referenceLineItemId: type: string referenceOrderID: type: string amount: type: number format: double currencyCode: type: string utid: type: string rewardName: type: string brandCode: type: string brandName: type: string status: type: string enum: - PENDING - FULFILLED - CANCELLED - FROZEN createdAt: type: string format: date-time fulfillment: $ref: '#/components/schemas/Fulfillment' CreateOrderRequest: type: object required: - customerIdentifier - accountIdentifier - amount - utid - recipient - sender properties: customerIdentifier: type: string accountIdentifier: type: string amount: type: number format: double description: Value of the reward in the account currency utid: type: string description: The Universal Token ID of the reward product recipient: $ref: '#/components/schemas/Recipient' sender: $ref: '#/components/schemas/Sender' message: type: string description: Optional custom message to include in the reward notes: type: string etid: type: string description: Email template ID to use for delivery externalRefID: type: string description: Optional external reference ID for your system sendEmail: type: boolean default: true description: Whether to send reward via email Order: type: object properties: referenceOrderID: type: string description: Unique order reference identifier orderRefID: type: string customerIdentifier: type: string accountIdentifier: type: string amount: type: number format: double currencyCode: type: string status: type: string lineItems: type: array items: $ref: '#/components/schemas/LineItem' createdAt: type: string format: date-time Fulfillment: type: object properties: fulfillmentType: type: string cardNumber: type: string cardPin: type: string redemptionUrl: type: string credentialList: type: array items: type: object properties: label: type: string value: type: string Recipient: type: object required: - name - email properties: name: type: string email: type: string format: email Error: type: object properties: timestamp: type: string format: date-time requestId: type: string path: type: string httpStatusCode: type: integer httpStatus: type: string message: type: string errors: type: array items: type: object properties: field: type: string message: type: string Sender: type: object required: - name - email properties: name: type: string email: type: string format: email parameters: referenceOrderID: name: referenceOrderID in: path required: true schema: type: string description: The reference order ID responses: BadRequest: description: Bad request - invalid parameters or missing required fields content: application/json: schema: $ref: '#/components/schemas/Error' securitySchemes: basicAuth: type: http scheme: basic description: HTTP Basic Auth using platform credentials (username/password)