Spiko Webhook Configurations API

The Webhook Configurations API from Spiko — 5 operation(s) for webhook configurations.

OpenAPI Specification

spiko-webhook-configurations-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Spiko Distributor Account transactions Webhook Configurations 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 Configurations
paths:
  /v0/webhook-configurations:
    post:
      tags:
      - Webhook Configurations
      operationId: webhookConfigurations.createWebhookConfiguration
      parameters: []
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                - id
                - distributorId
                - url
                - topics
                - signingSecret
                - previousSigningSecret
                - secretRotatedAt
                - status
                - consecutiveFailures
                - createdAt
                - updatedAt
                properties:
                  id:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  distributorId:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  url:
                    type: string
                  topics:
                    type: array
                    minItems: 1
                    items:
                      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
                  signingSecret:
                    type: string
                  previousSigningSecret:
                    anyOf:
                    - type: string
                    - type: 'null'
                  secretRotatedAt:
                    anyOf:
                    - type: string
                      title: valid range date
                      description: A valid date within the range 2020-2100
                    - type: 'null'
                  status:
                    type: string
                    enum:
                    - active
                    - disabled
                    - circuit-broken
                  consecutiveFailures:
                    $ref: '#/components/schemas/NonNegativeInt'
                  createdAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                  updatedAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                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: Register a new webhook endpoint. The signing secret is returned only in this response - store it securely.
      summary: Create a webhook configuration
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
              - url
              - topics
              properties:
                url:
                  type: string
                topics:
                  type: array
                  minItems: 1
                  items:
                    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
              additionalProperties: false
        required: true
    get:
      tags:
      - Webhook Configurations
      operationId: webhookConfigurations.listWebhookConfigurations
      parameters: []
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  required:
                  - id
                  - distributorId
                  - url
                  - topics
                  - status
                  - consecutiveFailures
                  - createdAt
                  - updatedAt
                  properties:
                    id:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    distributorId:
                      type: string
                      description: a Universally Unique Identifier
                      format: uuid
                    url:
                      type: string
                    topics:
                      type: array
                      minItems: 1
                      items:
                        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
                    status:
                      type: string
                      enum:
                      - active
                      - disabled
                      - circuit-broken
                    consecutiveFailures:
                      $ref: '#/components/schemas/NonNegativeInt'
                    createdAt:
                      type: string
                      title: valid range date
                      description: A valid date within the range 2020-2100
                    updatedAt:
                      type: string
                      title: valid range date
                      description: A valid date within the range 2020-2100
                  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: List all webhook configurations for the authenticated distributor.
      summary: List webhook configurations
  /v0/webhook-configurations/{webhookConfigurationId}:
    put:
      tags:
      - Webhook Configurations
      operationId: webhookConfigurations.updateWebhookConfiguration
      parameters:
      - name: webhookConfigurationId
        in: path
        schema:
          type: string
          description: a Universally Unique Identifier
          format: uuid
        required: true
        description: a Universally Unique Identifier
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                - id
                - distributorId
                - url
                - topics
                - status
                - consecutiveFailures
                - createdAt
                - updatedAt
                properties:
                  id:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  distributorId:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  url:
                    type: string
                  topics:
                    type: array
                    minItems: 1
                    items:
                      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
                  status:
                    type: string
                    enum:
                    - active
                    - disabled
                    - circuit-broken
                  consecutiveFailures:
                    $ref: '#/components/schemas/NonNegativeInt'
                  createdAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                  updatedAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                additionalProperties: false
        '400':
          description: The request did not match the expected schema
          content:
            application/json:
              schema:
                anyOf:
                - $ref: '#/components/schemas/HttpApiDecodeError'
                - $ref: '#/components/schemas/BadRequest'
        '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: Update the URL and topics of an active webhook configuration.
      summary: Update a webhook configuration
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
              - url
              - topics
              properties:
                url:
                  type: string
                topics:
                  type: array
                  minItems: 1
                  items:
                    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
              additionalProperties: false
        required: true
  /v0/webhook-configurations/{webhookConfigurationId}/disable:
    put:
      tags:
      - Webhook Configurations
      operationId: webhookConfigurations.disableWebhookConfiguration
      parameters:
      - name: webhookConfigurationId
        in: path
        schema:
          type: string
          description: a Universally Unique Identifier
          format: uuid
        required: true
        description: a Universally Unique Identifier
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                - id
                - distributorId
                - url
                - topics
                - status
                - consecutiveFailures
                - createdAt
                - updatedAt
                properties:
                  id:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  distributorId:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  url:
                    type: string
                  topics:
                    type: array
                    minItems: 1
                    items:
                      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
                  status:
                    type: string
                    enum:
                    - active
                    - disabled
                    - circuit-broken
                  consecutiveFailures:
                    $ref: '#/components/schemas/NonNegativeInt'
                  createdAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                  updatedAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                additionalProperties: false
        '400':
          description: The request did not match the expected schema
          content:
            application/json:
              schema:
                anyOf:
                - $ref: '#/components/schemas/HttpApiDecodeError'
                - $ref: '#/components/schemas/BadRequest'
        '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: Disable an active webhook configuration. No more events will be delivered to this endpoint.
      summary: Disable a webhook configuration
  /v0/webhook-configurations/{webhookConfigurationId}/enable:
    put:
      tags:
      - Webhook Configurations
      operationId: webhookConfigurations.enableWebhookConfiguration
      parameters:
      - name: webhookConfigurationId
        in: path
        schema:
          type: string
          description: a Universally Unique Identifier
          format: uuid
        required: true
        description: a Universally Unique Identifier
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                - id
                - distributorId
                - url
                - topics
                - status
                - consecutiveFailures
                - createdAt
                - updatedAt
                properties:
                  id:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  distributorId:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  url:
                    type: string
                  topics:
                    type: array
                    minItems: 1
                    items:
                      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
                  status:
                    type: string
                    enum:
                    - active
                    - disabled
                    - circuit-broken
                  consecutiveFailures:
                    $ref: '#/components/schemas/NonNegativeInt'
                  createdAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                  updatedAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                additionalProperties: false
        '400':
          description: The request did not match the expected schema
          content:
            application/json:
              schema:
                anyOf:
                - $ref: '#/components/schemas/HttpApiDecodeError'
                - $ref: '#/components/schemas/BadRequest'
        '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: Re-enable a disabled or circuit-broken webhook configuration.
      summary: Enable a webhook configuration
  /v0/webhook-configurations/{webhookConfigurationId}/rotate-secret:
    post:
      tags:
      - Webhook Configurations
      operationId: webhookConfigurations.rotateWebhookSigningSecret
      parameters:
      - name: webhookConfigurationId
        in: path
        schema:
          type: string
          description: a Universally Unique Identifier
          format: uuid
        required: true
        description: a Universally Unique Identifier
      security:
      - basicAuth: []
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                type: object
                required:
                - id
                - distributorId
                - url
                - topics
                - signingSecret
                - previousSigningSecret
                - secretRotatedAt
                - status
                - consecutiveFailures
                - createdAt
                - updatedAt
                properties:
                  id:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  distributorId:
                    type: string
                    description: a Universally Unique Identifier
                    format: uuid
                  url:
                    type: string
                  topics:
                    type: array
                    minItems: 1
                    items:
                      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
                  signingSecret:
                    type: string
                  previousSigningSecret:
                    anyOf:
                    - type: string
                    - type: 'null'
                  secretRotatedAt:
                    anyOf:
                    - type: string
                      title: valid range date
                      description: A valid date within the range 2020-2100
                    - type: 'null'
                  status:
                    type: string
                    enum:
                    - active
                    - disabled
                    - circuit-broken
                  consecutiveFailures:
                    $ref: '#/components/schemas/NonNegativeInt'
                  createdAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                  updatedAt:
                    type: string
                    title: valid range date
                    description: A valid date within the range 2020-2100
                additionalProperties: false
        '400':
          description: The request did not match the expected schema
          content:
            application/json:
              schema:
                anyOf:
                - $ref: '#/components/schemas/HttpApiDecodeError'
                - $ref: '#/components/schemas/BadRequest'
        '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: Generate a new signing secret. Both old and new secrets are valid for 24 hours. The new secret is returned only in this response.
      summary: Rotate the signing secret
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
    BadRequest:
      $id: /schemas/void
      title: BadRequest
    NonNegativeInt:
      type: integer
      description: an integer
      title: int
      minimum: 0
    HttpApiDecodeError:
      type: object
      required:
      - issues
      - message
   

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