Spiko Webhook Events API

The Webhook Events API from Spiko — 1 operation(s) for webhook events.

OpenAPI Specification

spiko-webhook-events-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Spiko Distributor Account transactions Webhook Events 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: Webhook Events
paths:
  /v0/webhook-events:
    get:
      tags:
      - Webhook Events
      operationId: webhookEvents.listWebhookEvents
      parameters:
      - name: after
        in: query
        schema:
          $ref: '#/components/schemas/NumberFromString'
        required: false
      - name: eventType
        in: query
        schema:
          type: string
          enum:
          - account.internal.created
          - deposit-order.created
          - deposit-order.funded
          - deposit-order.executed
          - deposit-order.canceled
          - subscription-order.created
          - subscription-order.executed
          - subscription-order.canceled
          - subscription-order.wire-validated
          - redemption-order.created
          - redemption-order.executed
          - redemption-order.canceled
          - withdrawal-order.pending
          - withdrawal-order.executed
          - withdrawal-order.canceled
          - transfer-order.created
          - transfer-order.executed
          - investor.created
          - investor.updated
          - investor.activated
          - investor.made-compliant
          - investor.made-non-compliant
          - investor.archived
          - bank-account.created
          - bank-account.validated
          - bank-account.invalidated
          - bank-account.pending-validation
          - investor-invitation.accepted
          - yield.credited
        required: false
      - name: limit
        in: query
        schema:
          type: string
          description: a string to be decoded into a number
        required: false
        description: a string to be decoded into a number
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: array
                items:
                  anyOf:
                  - type: object
                    required:
                    - id
                    - sequenceNumber
                    - webhookConfigurationId
                    - distributorId
                    - eventType
                    - payload
                    - retryCount
                    - createdAt
                    - status
                    - httpStatusCode
                    - lastAttemptAt
                    - deliveredAt
                    properties:
                      id:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      sequenceNumber:
                        type: number
                      webhookConfigurationId:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      distributorId:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      eventType:
                        type: string
                        enum:
                        - account.internal.created
                        - deposit-order.created
                        - deposit-order.funded
                        - deposit-order.executed
                        - deposit-order.canceled
                        - subscription-order.created
                        - subscription-order.executed
                        - subscription-order.canceled
                        - subscription-order.wire-validated
                        - redemption-order.created
                        - redemption-order.executed
                        - redemption-order.canceled
                        - withdrawal-order.pending
                        - withdrawal-order.executed
                        - withdrawal-order.canceled
                        - transfer-order.created
                        - transfer-order.executed
                        - investor.created
                        - investor.updated
                        - investor.activated
                        - investor.made-compliant
                        - investor.made-non-compliant
                        - investor.archived
                        - bank-account.created
                        - bank-account.validated
                        - bank-account.invalidated
                        - bank-account.pending-validation
                        - investor-invitation.accepted
                        - yield.credited
                      payload:
                        $id: /schemas/unknown
                        title: unknown
                      retryCount:
                        $ref: '#/components/schemas/NonNegativeInt'
                      createdAt:
                        type: string
                        title: valid range date
                        description: A valid date within the range 2020-2100
                      status:
                        type: string
                        enum:
                        - pending
                      httpStatusCode:
                        anyOf:
                        - $ref: '#/components/schemas/Int'
                          description: a number between 100 and 599
                          title: between(100, 599)
                          minimum: 100
                          maximum: 599
                        - type: 'null'
                      lastAttemptAt:
                        anyOf:
                        - type: string
                          title: valid range date
                          description: A valid date within the range 2020-2100
                        - type: 'null'
                      deliveredAt:
                        anyOf:
                        - type: string
                          title: valid range date
                          description: A valid date within the range 2020-2100
                        - type: 'null'
                    additionalProperties: false
                  - type: object
                    required:
                    - id
                    - sequenceNumber
                    - webhookConfigurationId
                    - distributorId
                    - eventType
                    - payload
                    - retryCount
                    - createdAt
                    - status
                    - httpStatusCode
                    - lastAttemptAt
                    - deliveredAt
                    properties:
                      id:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      sequenceNumber:
                        type: number
                      webhookConfigurationId:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      distributorId:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      eventType:
                        type: string
                        enum:
                        - account.internal.created
                        - deposit-order.created
                        - deposit-order.funded
                        - deposit-order.executed
                        - deposit-order.canceled
                        - subscription-order.created
                        - subscription-order.executed
                        - subscription-order.canceled
                        - subscription-order.wire-validated
                        - redemption-order.created
                        - redemption-order.executed
                        - redemption-order.canceled
                        - withdrawal-order.pending
                        - withdrawal-order.executed
                        - withdrawal-order.canceled
                        - transfer-order.created
                        - transfer-order.executed
                        - investor.created
                        - investor.updated
                        - investor.activated
                        - investor.made-compliant
                        - investor.made-non-compliant
                        - investor.archived
                        - bank-account.created
                        - bank-account.validated
                        - bank-account.invalidated
                        - bank-account.pending-validation
                        - investor-invitation.accepted
                        - yield.credited
                      payload:
                        $id: /schemas/unknown
                        title: unknown
                      retryCount:
                        $ref: '#/components/schemas/NonNegativeInt'
                      createdAt:
                        type: string
                        title: valid range date
                        description: A valid date within the range 2020-2100
                      status:
                        type: string
                        enum:
                        - delivered
                      httpStatusCode:
                        $ref: '#/components/schemas/Int'
                        description: a number between 100 and 599
                        title: between(100, 599)
                        minimum: 100
                        maximum: 599
                      lastAttemptAt:
                        type: string
                        title: valid range date
                        description: A valid date within the range 2020-2100
                      deliveredAt:
                        type: string
                        title: valid range date
                        description: A valid date within the range 2020-2100
                    additionalProperties: false
                  - type: object
                    required:
                    - id
                    - sequenceNumber
                    - webhookConfigurationId
                    - distributorId
                    - eventType
                    - payload
                    - retryCount
                    - createdAt
                    - status
                    - httpStatusCode
                    - lastAttemptAt
                    - deliveredAt
                    properties:
                      id:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      sequenceNumber:
                        type: number
                      webhookConfigurationId:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      distributorId:
                        type: string
                        description: a Universally Unique Identifier
                        format: uuid
                      eventType:
                        type: string
                        enum:
                        - account.internal.created
                        - deposit-order.created
                        - deposit-order.funded
                        - deposit-order.executed
                        - deposit-order.canceled
                        - subscription-order.created
                        - subscription-order.executed
                        - subscription-order.canceled
                        - subscription-order.wire-validated
                        - redemption-order.created
                        - redemption-order.executed
                        - redemption-order.canceled
                        - withdrawal-order.pending
                        - withdrawal-order.executed
                        - withdrawal-order.canceled
                        - transfer-order.created
                        - transfer-order.executed
                        - investor.created
                        - investor.updated
                        - investor.activated
                        - investor.made-compliant
                        - investor.made-non-compliant
                        - investor.archived
                        - bank-account.created
                        - bank-account.validated
                        - bank-account.invalidated
                        - bank-account.pending-validation
                        - investor-invitation.accepted
                        - yield.credited
                      payload:
                        $id: /schemas/unknown
                        title: unknown
                      retryCount:
                        $ref: '#/components/schemas/NonNegativeInt'
                      createdAt:
                        type: string
                        title: valid range date
                        description: A valid date within the range 2020-2100
                      status:
                        type: string
                        enum:
                        - failed
                      httpStatusCode:
                        anyOf:
                        - $ref: '#/components/schemas/Int'
                          description: a number between 100 and 599
                          title: between(100, 599)
                          minimum: 100
                          maximum: 599
                        - type: 'null'
                      lastAttemptAt:
                        anyOf:
                        - type: string
                          title: valid range date
                          description: A valid date within the range 2020-2100
                        - type: 'null'
                      deliveredAt:
                        anyOf:
                        - type: string
                          title: valid range date
                          description: A valid date within the range 2020-2100
                        - type: 'null'
                    additionalProperties: false
        '400':
          description: The request did not match the expected schema
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HttpApiDecodeError'
        '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'
      description: Retrieve webhook events using cursor-based pagination. Pass the last `sequenceNumber` as `after` to get the next page.
      summary: Poll webhook events
components:
  schemas:
    ForbiddenError:
      type: object
      required:
      - reason
      - _tag
      properties:
        reason:
          type: string
        customErrorCode:
          type: string
          enum:
          - AccountDoesNotBelongToInvestor
          - SessionIsNot2FA
          - InvestorDocumentLinkedToActiveBankAccount
          - AtLeastTwoAdminUsersRequired
          - InvestorNotPendingOnboarding
          - ShareClassNotAvailableForDistributor
        _tag:
          type: string
          enum:
          - ForbiddenError
      additionalProperties: false
      description: Forbidden
    NonNegativeInt:
      type: integer
      description: an integer
      title: int
      minimum: 0
    HttpApiDecodeError:
      type: object
      required:
      - issues
      - message
      - _tag
      properties:
        issues:
          type: array
          items:
            $ref: '#/components/schemas/Issue'
        message:
          type: string
        _tag:
          type: string
          enum:
          - HttpApiDecodeError
      additionalProperties: false
      description: The request did not match the expected schema
    Issue:
      type: object
      required:
      - _tag
      - path
      - message
      properties:
        _tag:
          type: string
          enum:
          - Pointer
          - Unexpected
          - Missing
          - Composite
          - Refinement
          - Transformation
          - Type
          - Forbidden
          description: The tag identifying the type of parse issue
        path:
          type: array
          items:
            $ref: '#/components/schemas/PropertyKey'
          description: The path to the property where the issue occurred
        message:
          type: string
          description: A descriptive message explaining the issue
      additionalProperties: false
      description: Represents an error encountered while parsing a value to match the schema
    Int:
      type: integer
      description: an integer
      title: int
    NumberFromString:
      type: string
      description: a string to be decoded into a number
    DistributorAuthenticationError:
      type: object
      required:
      - reason
      - _tag
      properties:
        reason:
          type: string
        _tag:
          type: string
          enum:
          - DistributorAuthenticationError
      additionalProperties: false
      description: Authentication Error
    Unauthorized:
      $id: /schemas/void
      title: Unauthorized
    PropertyKey:
      anyOf:
      - type: string
      - type: number
      - type: object
        required:
        - _tag
        - key
        properties:
          _tag:
            type: string
            enum:
            - symbol
          key:
            type: string
        additionalProperties: false
        description: an object to be decoded into a globally shared symbol
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: Use your API client_id as username and client_secret as password.