Rillet Customer Payments API

The Customer Payments API from Rillet — 1 operation(s) for customer payments.

OpenAPI Specification

rillet-customer-payments-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Rillet Accounting API Key Customer Payments API
  version: v4.0
servers:
- url: https://api.rillet.com
  description: Production server url
- url: https://sandbox.api.rillet.com
  description: Test server url
security:
- bearerAuth: []
tags:
- name: Customer Payments
paths:
  /customers/{customer_id}/settings/payment:
    post:
      tags:
      - Customer Payments
      operationId: setup-auto-payment
      summary: Sets up auto-payment
      description: Kicks off the setup of auto-payment for a customer. This will return a URL that the customer must visit to complete the setup. If the customer already has a payment method, this will return a URL to update the payment method.
      parameters:
      - name: customer_id
        in: path
        description: UUID of the customer to be used in this operation.
        required: true
        schema:
          type: string
          format: uuid
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SetupUpAutoPaymentRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaymentSetupResponse'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
    get:
      tags:
      - Customer Payments
      operationId: get-payment-method
      summary: Gets payment method
      description: Returns the payment method configured for auto-payment for the given customer.
      parameters:
      - name: customer_id
        in: path
        description: UUID of the customer to be used in this operation.
        required: true
        schema:
          type: string
          format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CustomerPaymentMethod'
        default:
          description: Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    PaymentSetupResponse:
      type: object
      required:
      - setup_url
      properties:
        setup_url:
          type: string
          format: uri
          description: URL to the payment setup portal
    CustomerPaymentMethod:
      type: object
      required:
      - chargeable
      - payment_type
      properties:
        last_four_digits:
          type: string
          description: The last four digits of the payment method.
        chargeable:
          type: boolean
          description: Whether the payment method can be used or not. If false, further action from the customer might be required.
        payment_type:
          type: string
          enum:
          - CARD
          - BANK_ACCOUNT
          - OTHER
    SetupUpAutoPaymentRequest:
      type: object
      optional:
      - subsidiary_id
      properties:
        subsidiary_id:
          type: string
          format: uuid
    Error:
      type: object
      required:
      - type
      - title
      properties:
        type:
          type: string
          format: uri
          description: A URI reference that identifies the error type.
          example: https://rillet.io/forbidden
        title:
          type: string
          description: Summary of the problem.
          example: Forbidden
        status:
          type: integer
          description: The HTTP status code generated by the origin server for this occurrence of the error.
          example: 403
        detail:
          type: string
          description: Explanation specific to this occurrence of the error.
          example: User does not have rights to perform this operation.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
x-mcp-ready: true
x-readme:
  headers:
  - key: X-Rillet-API-Version
    value: '4'