openapi: 3.2.0 info: title: Carbon Arc API Documentation Clients API description: '# Introduction Carbon Arc''s Insights Exchange provides a comprehensive consumption-based platform for accessing decision-making data.' version: v2 x-logo: url: /static/logo_light.png tags: - name: Clients paths: /v2/clients/payments/balance-summary: get: tags: - Clients summary: Get Client Balance description: Get the balance of a client operationId: get_client_balance_v2_clients_payments_balance_summary_get requestBody: content: application/json: schema: anyOf: - type: object - type: 'null' title: Config responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/ClientBalanceResponse' '404': description: Not Found detail: Not found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v2/clients/me/orders: get: tags: - Clients summary: Get User Orders operationId: get_user_orders_v2_clients_me_orders_get parameters: - name: page in: query required: false schema: type: integer minimum: 1 default: 1 title: Page - name: size in: query required: false schema: type: integer minimum: 0 default: 25 title: Size - name: order_by in: query required: false schema: type: string default: created_at title: Order By - name: order in: query required: false schema: type: string pattern: ^(asc|desc)$ default: desc title: Order - name: user_email in: query required: false schema: type: array items: type: string title: User Email - name: date_from in: query required: false schema: type: string format: date-time title: Date From - name: date_to in: query required: false schema: type: string format: date-time title: Date To - name: search in: query required: false schema: type: string description: Search by display_name title: Search description: Search by display_name - name: order_type in: query required: false schema: type: array items: type: string description: Filter by order type (e.g., new_purchase, renewal, upgrade) title: Order Type description: Filter by order type (e.g., new_purchase, renewal, upgrade) - name: type in: query required: false schema: type: array items: type: string description: 'Filter by category (e.g., exchange, framework, cohortbuilder, tribes, transcript). ''tribes'' and ''framework'' are both type=''framework'' rows split by Order.source (PRO-1450). ''transcript'' rows are account-scoped: visible to every user on the same client, not just the original purchaser (PRO-1859).' title: Type description: 'Filter by category (e.g., exchange, framework, cohortbuilder, tribes, transcript). ''tribes'' and ''framework'' are both type=''framework'' rows split by Order.source (PRO-1450). ''transcript'' rows are account-scoped: visible to every user on the same client, not just the original purchaser (PRO-1859).' requestBody: content: application/json: schema: anyOf: - type: object - type: 'null' title: Config responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/OrderPaginatedResponse' '404': detail: Not found description: Not Found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v2/clients/me/orders/{order_id}: get: tags: - Clients summary: Get User Order description: Endpoint for fetching specific user order's details operationId: get_user_order_v2_clients_me_orders__order_id__get parameters: - name: order_id in: path required: true schema: type: string format: uuid title: Order Id requestBody: content: application/json: schema: anyOf: - type: object - type: 'null' title: Config responses: '200': description: Successful Response content: application/json: schema: anyOf: - $ref: '#/components/schemas/FrameworkOrderRead' - $ref: '#/components/schemas/OrderInformationResponse' title: Response Get User Order V2 Clients Me Orders Order Id Get '404': detail: Not found description: Not Found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' patch: tags: - Clients summary: Update User Order Display Name description: Endpoint for updating a user's order display name operationId: update_user_order_display_name_v2_clients_me_orders__order_id__patch parameters: - name: order_id in: path required: true schema: type: string format: uuid title: Order Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/Body_update_user_order_display_name_v2_clients_me_orders__order_id__patch' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/OrderUpdateResponse' '404': detail: Not found description: Not Found '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' components: schemas: FrameworkOrderRead: properties: id: type: string format: uuid title: Id order_id: anyOf: - type: string - type: 'null' title: Order Id default: '' name: type: string title: Name display_name: anyOf: - type: string - type: 'null' title: Display Name type: type: string title: Type user_email: type: string title: User Email total_records_count: type: integer title: Total Records Count total_price: type: number title: Total Price created_at: type: string format: date-time title: Created At updated_at: type: string format: date-time title: Updated At order_type: type: string enum: - new_purchase - refresh_purchase - reinstatement_purchase - repurchase title: Order Type source: anyOf: - type: string - type: 'null' title: Source transcript_id: anyOf: - type: string format: uuid - type: 'null' title: Transcript Id framework_ids: items: type: string format: uuid type: array title: Framework Ids framework_details: items: type: object type: array title: Framework Details framework_id_remap: additionalProperties: type: string format: uuid propertyNames: format: uuid type: object title: Framework Id Remap type: object required: - id - name - type - user_email - total_records_count - total_price - created_at - updated_at - order_type - framework_ids - framework_details title: FrameworkOrderRead HTTPValidationError: properties: detail: items: $ref: '#/components/schemas/ValidationError' type: array title: Detail type: object title: HTTPValidationError OrderInformationResponse: properties: id: type: string format: uuid title: Id name: anyOf: - type: string - type: 'null' title: Name display_name: anyOf: - type: string - type: 'null' title: Display Name type: type: string title: Type user_email: type: string title: User Email total_price: type: number title: Total Price created_at: type: string format: date-time title: Created At updated_at: type: string format: date-time title: Updated At framework_ids: items: type: string format: uuid type: array title: Framework Ids framework_details: items: type: object type: array title: Framework Details order_type: type: string enum: - new_purchase - refresh_purchase - reinstatement_purchase - repurchase title: Order Type source: anyOf: - type: string - type: 'null' title: Source framework_id_remap: additionalProperties: type: string format: uuid propertyNames: format: uuid type: object title: Framework Id Remap type: object required: - id - name - type - user_email - total_price - created_at - updated_at - framework_ids - framework_details - order_type title: OrderInformationResponse Body_update_user_order_display_name_v2_clients_me_orders__order_id__patch: properties: display_name: type: string title: Display Name config: anyOf: - type: object - type: 'null' title: Config type: object required: - display_name title: Body_update_user_order_display_name_v2_clients_me_orders__order_id__patch OrderUpdateResponse: properties: id: type: string format: uuid title: Id name: type: string title: Name display_name: anyOf: - type: string - type: 'null' title: Display Name type: type: string title: Type user_email: type: string title: User Email created_at: type: string format: date-time title: Created At updated_at: type: string format: date-time title: Updated At order_type: type: string enum: - new_purchase - refresh_purchase - reinstatement_purchase - repurchase title: Order Type type: object required: - id - name - type - user_email - created_at - updated_at - order_type title: OrderUpdateResponse ValidationError: properties: loc: items: anyOf: - type: string - type: integer type: array title: Location msg: type: string title: Message type: type: string title: Error Type input: title: Input ctx: type: object title: Context type: object required: - loc - msg - type title: ValidationError ExpiryScheduleItem: properties: amount: type: number title: Amount expires_at: type: string format: date-time title: Expires At token_type: type: string title: Token Type type: object required: - amount - expires_at - token_type title: ExpiryScheduleItem ClientBalanceResponse: properties: total_balance: type: number title: Total Balance promotional_balance: type: number title: Promotional Balance purchased_balance: type: number title: Purchased Balance expiry_schedule: items: $ref: '#/components/schemas/ExpiryScheduleItem' type: array title: Expiry Schedule type: object required: - total_balance - promotional_balance - purchased_balance - expiry_schedule title: ClientBalanceResponse OrderPaginatedResponse: properties: total: type: integer title: Total page: type: integer title: Page size: type: integer title: Size pages: type: integer title: Pages items: items: $ref: '#/components/schemas/FrameworkOrderRead' type: array title: Items type: object required: - total - page - size - pages - items title: OrderPaginatedResponse