Spiko Bank accounts API

The Bank accounts API from Spiko — 5 operation(s) for bank accounts.

OpenAPI Specification

spiko-bank-accounts-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Spiko Distributor Account transactions Bank accounts API
  version: v0
  description: The Distributor API allows third parties like SaaS providers, fintechs or Web3 companies to distribute the Spiko Funds to their customers. With this API, you can programmatically manage investors, send subscription and redemption orders, and access real-time portfolio information.
servers:
- url: https://distributor-api.spiko.io
  description: Production Server
- url: https://distributor-api.preprod.spiko.io
  description: Pre-production Server
security: []
tags:
- name: Bank accounts
paths:
  /v0/bank-accounts:
    post:
      tags:
      - Bank accounts
      operationId: bankAccounts.addBankAccount
      parameters: []
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                anyOf:
                - type: object
                  required:
                  - id
                  - investorId
                  - details
                  - createdAt
                  - name
                  - proofInvestorDocumentId
                  - mandate
                  - vop
                  - status
                  properties:
                    id:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    investorId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    details:
                      anyOf:
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - bic
                        properties:
                          currency:
                            type: string
                            enum:
                            - EUR
                          accountNumber:
                            title: IBAN
                            type: string
                            description: a valid IBAN (International Bank Account Number)
                          bic:
                            anyOf:
                            - title: BIC
                              type: string
                              description: A valid BIC (Bank Identifier Code)
                            - type: 'null'
                        additionalProperties: false
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - sortCode
                        properties:
                          currency:
                            type: string
                            enum:
                            - GBP
                          accountNumber:
                            type: string
                            title: UK Bank Account Number
                            description: a valid UK Bank Account Number (8 digits)
                          sortCode:
                            type: string
                            title: Sort Code
                            description: A valid UK Sort Code (6 digits)
                        additionalProperties: false
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - bic
                        - intermediaryBic
                        properties:
                          currency:
                            type: string
                            enum:
                            - USD
                            - GBP
                            - CHF
                            - JPY
                            - SGD
                          accountNumber:
                            anyOf:
                            - title: IBAN
                              type: string
                              description: a valid IBAN (International Bank Account Number)
                            - type: string
                              title: US Bank Account Number
                              description: a valid US Bank Account Number
                          bic:
                            title: BIC
                            type: string
                            description: A valid BIC (Bank Identifier Code)
                          intermediaryBic:
                            anyOf:
                            - title: BIC
                              type: string
                              description: A valid BIC (Bank Identifier Code)
                            - type: 'null'
                          address:
                            anyOf:
                            - type: object
                              required:
                              - street
                              - city
                              - zipCode
                              - country
                              properties:
                                street:
                                  $ref: '#/components/schemas/NonEmptyString'
                                city:
                                  $ref: '#/components/schemas/NonEmptyString'
                                zipCode:
                                  $ref: '#/components/schemas/NonEmptyString'
                                country:
                                  $ref: '#/components/schemas/CountryCodeAlpha2'
                              additionalProperties: false
                            - type: 'null'
                        additionalProperties: false
                    createdAt:
                      type: string
                      title: valid range date
                      description: A valid date within the range 2020-2100
                    name:
                      anyOf:
                      - $ref: '#/components/schemas/NonEmptyString'
                        description: a string at most 255 character(s) long
                        title: maxLength(255)
                        maxLength: 255
                      - type: 'null'
                    proofInvestorDocumentId:
                      anyOf:
                      - type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      - type: 'null'
                    mandate:
                      anyOf:
                      - anyOf:
                        - type: object
                          required:
                          - mandateReference
                          - mandateStatus
                          - mandateSignedAt
                          - externalMandateId
                          properties:
                            mandateReference:
                              type: string
                              description: a string matching the pattern ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                              pattern: ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                            mandateStatus:
                              type: string
                              enum:
                              - pending-signature
                            mandateSignedAt:
                              type: 'null'
                            externalMandateId:
                              type: string
                              description: a Universally Unique Identifier
                              format: uuid
                          additionalProperties: false
                        - type: object
                          required:
                          - mandateReference
                          - mandateStatus
                          - mandateSignedAt
                          - externalMandateId
                          properties:
                            mandateReference:
                              type: string
                              description: a string matching the pattern ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                              pattern: ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                            mandateStatus:
                              type: string
                              enum:
                              - signed
                            mandateSignedAt:
                              type: string
                              title: valid range date
                              description: A valid date within the range 2020-2100
                            externalMandateId:
                              type: string
                              description: a Universally Unique Identifier
                              format: uuid
                          additionalProperties: false
                      - type: 'null'
                    vop:
                      type: 'null'
                      deprecated: true
                      description: Deprecated. Always null.
                    status:
                      type: string
                      enum:
                      - validated
                  additionalProperties: false
                - type: object
                  required:
                  - id
                  - investorId
                  - details
                  - createdAt
                  - name
                  - proofInvestorDocumentId
                  - mandate
                  - vop
                  - status
                  properties:
                    id:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    investorId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    details:
                      anyOf:
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - bic
                        properties:
                          currency:
                            type: string
                            enum:
                            - EUR
                          accountNumber:
                            title: IBAN
                            type: string
                            description: a valid IBAN (International Bank Account Number)
                          bic:
                            anyOf:
                            - title: BIC
                              type: string
                              description: A valid BIC (Bank Identifier Code)
                            - type: 'null'
                        additionalProperties: false
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - sortCode
                        properties:
                          currency:
                            type: string
                            enum:
                            - GBP
                          accountNumber:
                            type: string
                            title: UK Bank Account Number
                            description: a valid UK Bank Account Number (8 digits)
                          sortCode:
                            type: string
                            title: Sort Code
                            description: A valid UK Sort Code (6 digits)
                        additionalProperties: false
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - bic
                        - intermediaryBic
                        properties:
                          currency:
                            type: string
                            enum:
                            - USD
                            - GBP
                            - CHF
                            - JPY
                            - SGD
                          accountNumber:
                            anyOf:
                            - title: IBAN
                              type: string
                              description: a valid IBAN (International Bank Account Number)
                            - type: string
                              title: US Bank Account Number
                              description: a valid US Bank Account Number
                          bic:
                            title: BIC
                            type: string
                            description: A valid BIC (Bank Identifier Code)
                          intermediaryBic:
                            anyOf:
                            - title: BIC
                              type: string
                              description: A valid BIC (Bank Identifier Code)
                            - type: 'null'
                          address:
                            anyOf:
                            - type: object
                              required:
                              - street
                              - city
                              - zipCode
                              - country
                              properties:
                                street:
                                  $ref: '#/components/schemas/NonEmptyString'
                                city:
                                  $ref: '#/components/schemas/NonEmptyString'
                                zipCode:
                                  $ref: '#/components/schemas/NonEmptyString'
                                country:
                                  $ref: '#/components/schemas/CountryCodeAlpha2'
                              additionalProperties: false
                            - type: 'null'
                        additionalProperties: false
                    createdAt:
                      type: string
                      title: valid range date
                      description: A valid date within the range 2020-2100
                    name:
                      anyOf:
                      - $ref: '#/components/schemas/NonEmptyString'
                        description: a string at most 255 character(s) long
                        title: maxLength(255)
                        maxLength: 255
                      - type: 'null'
                    proofInvestorDocumentId:
                      anyOf:
                      - type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      - type: 'null'
                    mandate:
                      anyOf:
                      - anyOf:
                        - type: object
                          required:
                          - mandateReference
                          - mandateStatus
                          - mandateSignedAt
                          - externalMandateId
                          properties:
                            mandateReference:
                              type: string
                              description: a string matching the pattern ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                              pattern: ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                            mandateStatus:
                              type: string
                              enum:
                              - pending-signature
                            mandateSignedAt:
                              type: 'null'
                            externalMandateId:
                              type: string
                              description: a Universally Unique Identifier
                              format: uuid
                          additionalProperties: false
                        - type: object
                          required:
                          - mandateReference
                          - mandateStatus
                          - mandateSignedAt
                          - externalMandateId
                          properties:
                            mandateReference:
                              type: string
                              description: a string matching the pattern ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                              pattern: ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                            mandateStatus:
                              type: string
                              enum:
                              - signed
                            mandateSignedAt:
                              type: string
                              title: valid range date
                              description: A valid date within the range 2020-2100
                            externalMandateId:
                              type: string
                              description: a Universally Unique Identifier
                              format: uuid
                          additionalProperties: false
                      - type: 'null'
                    vop:
                      type: 'null'
                      deprecated: true
                      description: Deprecated. Always null.
                    status:
                      type: string
                      enum:
                      - pending-vop
                  additionalProperties: false
                - type: object
                  required:
                  - id
                  - investorId
                  - details
                  - createdAt
                  - name
                  - proofInvestorDocumentId
                  - mandate
                  - vop
                  - status
                  properties:
                    id:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    investorId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    details:
                      anyOf:
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - bic
                        properties:
                          currency:
                            type: string
                            enum:
                            - EUR
                          accountNumber:
                            title: IBAN
                            type: string
                            description: a valid IBAN (International Bank Account Number)
                          bic:
                            anyOf:
                            - title: BIC
                              type: string
                              description: A valid BIC (Bank Identifier Code)
                            - type: 'null'
                        additionalProperties: false
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - sortCode
                        properties:
                          currency:
                            type: string
                            enum:
                            - GBP
                          accountNumber:
                            type: string
                            title: UK Bank Account Number
                            description: a valid UK Bank Account Number (8 digits)
                          sortCode:
                            type: string
                            title: Sort Code
                            description: A valid UK Sort Code (6 digits)
                        additionalProperties: false
                      - type: object
                        required:
                        - currency
                        - accountNumber
                        - bic
                        - intermediaryBic
                        properties:
                          currency:
                            type: string
                            enum:
                            - USD
                            - GBP
                            - CHF
                            - JPY
                            - SGD
                          accountNumber:
                            anyOf:
                            - title: IBAN
                              type: string
                              description: a valid IBAN (International Bank Account Number)
                            - type: string
                              title: US Bank Account Number
                              description: a valid US Bank Account Number
                          bic:
                            title: BIC
                            type: string
                            description: A valid BIC (Bank Identifier Code)
                          intermediaryBic:
                            anyOf:
                            - title: BIC
                              type: string
                              description: A valid BIC (Bank Identifier Code)
                            - type: 'null'
                          address:
                            anyOf:
                            - type: object
                              required:
                              - street
                              - city
                              - zipCode
                              - country
                              properties:
                                street:
                                  $ref: '#/components/schemas/NonEmptyString'
                                city:
                                  $ref: '#/components/schemas/NonEmptyString'
                                zipCode:
                                  $ref: '#/components/schemas/NonEmptyString'
                                country:
                                  $ref: '#/components/schemas/CountryCodeAlpha2'
                              additionalProperties: false
                            - type: 'null'
                        additionalProperties: false
                    createdAt:
                      type: string
                      title: valid range date
                      description: A valid date within the range 2020-2100
                    name:
                      anyOf:
                      - $ref: '#/components/schemas/NonEmptyString'
                        description: a string at most 255 character(s) long
                        title: maxLength(255)
                        maxLength: 255
                      - type: 'null'
                    proofInvestorDocumentId:
                      anyOf:
                      - type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      - type: 'null'
                    mandate:
                      anyOf:
                      - anyOf:
                        - type: object
                          required:
                          - mandateReference
                          - mandateStatus
                          - mandateSignedAt
                          - externalMandateId
                          properties:
                            mandateReference:
                              type: string
                              description: a string matching the pattern ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                              pattern: ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                            mandateStatus:
                              type: string
                              enum:
                              - pending-signature
                            mandateSignedAt:
                              type: 'null'
                            externalMandateId:
                              type: string
                              description: a Universally Unique Identifier
                              format: uuid
                          additionalProperties: false
                        - type: object
                          required:
                          - mandateReference
                          - mandateStatus
                          - mandateSignedAt
                          - externalMandateId
                          properties:
                            mandateReference:
                              type: string
                              description: a string matching the pattern ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                              pattern: ^[A-Za-z0-9+?/\-:().,'\s]{1,35}$
                            mandateStatus:
                              type: string
                              enum:
                              - signed
                            mandateSignedAt:
                              type: string
                              title: valid range date
                              description: A valid date within the range 2020-2100
                            externalMandateId:
                              type: string
                              description: a Universally Unique Identifier
                              format: uuid
                          additionalProperties: false
                      - type: 'null'
                    vop:
                      type: 'null'
                      deprecated: true
                      description: Deprecated. Always null.
                    status:
                      type: string
                      enum:
                      - pending-validation
                  additionalProperties: false
        '400':
          description: The request did not match the expected schema
          content:
            application/json:
              schema:
                anyOf:
                - $ref: '#/components/schemas/HttpApiDecodeError'
                - $ref: '#/components/schemas/ProofDocumentRequiredError'
                - $ref: '#/components/schemas/BadRequestError'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                anyOf:
                - $ref: '#/components/schemas/Unauthorized'
                - $ref: '#/components/schemas/DistributorAuthenticationError'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ForbiddenError'
        '404':
          description: NotFound
      description: "\n**Create a new bank account, linked to an existing investor, and for a given currency.**\n\n- Link the specified banking details to the investor's profile for future withdrawals processing.\n- EUR/GBP accounts may undergo automated verification (VoP/CoP). The bank account status will reflect the verification state.\n- Other currencies REQUIRE a proof of bank account ownership document (`proofInvestorDocumentId`).\n- Return complete bank account information.\n          "
      summary: Add bank account
      requestBody:
        content:
          application/json:
            schema:
              anyOf:
              - anyOf:
                - type: object
                  required:
                  - currency
                  - accountNumber
                  - bic
                  - investorId
                  properties:
                    currency:
                      type: string
                      enum:
                      - EUR
                    accountNumber:
                      title: IBAN
                      type: string
                      description: a valid IBAN (International Bank Account Number)
                    bic:
                      anyOf:
                      - title: BIC
                        type: string
                        description: A valid BIC (Bank Identifier Code)
                      - type: 'null'
                    investorId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    proofInvestorDocumentId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                  additionalProperties: false
                - type: object
                  required:
                  - currency
                  - accountNumber
                  - sortCode
                  - investorId
                  properties:
                    currency:
                      type: string
                      enum:
                      - GBP
                    accountNumber:
                      type: string
                      title: UK Bank Account Number
                      description: a valid UK Bank Account Number (8 digits)
                    sortCode:
                      type: string
                      title: Sort Code
                      description: A valid UK Sort Code (6 digits)
                    investorId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    proofInvestorDocumentId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                  additionalProperties: false
              - type: object
                required:
                - currency
                - accountNumber
                - bic
                - intermediaryBic
                - investorId
                properties:
                  currency:
                    type: string
                    enum:
                    - USD
                    - GBP
                    - CHF
                    - JPY
                    - SGD
                  accountNumber:
                    anyOf:
                    - title: IBAN
                      type: string
                      description: a valid IBAN (International Bank Account Number)
                    - type: string
                      title: US Bank Account Number
                      description: a valid US Bank Account Number
                  bic:
                    title: BIC
                    type: string
                    description: A valid BIC (Bank Identifier Code)
                  intermediaryBic:
                    anyOf:
                    - title: BIC
                      type: string
                      description: A valid BIC (Bank Identifier Code)
                    - type: 'null'
                  address:
                    anyOf:
                    - type: object
                      required:
                      - street
                      - city
                      - zipCode
                      - country
                      properties:
                        street:
                          $ref: '#/components/schemas/NonEmptyString'
                        city:
                          $ref: '#/components/schemas/NonEmptyString'
                        zipCode:
                          $ref: '#/components/schemas/NonEmptyString'
                        country:
                          $ref: '#/components/schemas/CountryCodeAlpha2'
                      additionalProperties: false
                    - type: 'null'
                  investorId:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  proofInvestorDocumentId:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                additionalProperties: false
        required: true
    get:
      tags:
      - Bank accounts
      operationId: bankAccounts.getBankAccounts
      parameters:
      - name: investorId
        in: query
        schema:
          type: string
          description: a Universally Unique Identifier
          format: uuid
        required: true
        description: a Universally Unique Identifier
      - name: currency
        in: query
        schema:
          type: string
          enum:
          - EUR
          - USD
          - GBP
          - CHF
        

# --- truncated at 32 KB (159 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/spiko/refs/heads/main/openapi/spiko-bank-accounts-api-openapi.yml