REST APIEnterpriseEnterprise Webhooks

POST

Create a webhook that will fire for any bank account associated with the enterprise. Must be an organization or enterprise admin to perform this action. To call this endpoint, you must have the user_manage scope on a short-lived access token created either in the web app or programmatically using the Login endpoint.

Path Params

  • enterpriseId string required

    matches ^[0-9a-f]{32}$

Body Params

object

  • type string enum required
    bankAccountaccessTokenpolicyBalanceChangereversal
  • url string required

    at least 1 characters

  • label string

Responses

200
OK

Response Body

object

Webhook response scoped to enterprise webhook types — coin is optional.
  • id string required

    matches ^[0-9a-f]{32}$

  • created string date-time required
  • url string uri required
  • version number required
    2 for coins running on API v2.
  • scope string enum required
    walletenterpriseorganizationsafe
  • state string enum required
    If 'active', indicates the webhook can trigger and send to the URL. If 'suspended', indicates the webhook can't trigger.
    activesuspended
  • successiveFailedAttempts number required
  • listenToFailureStates boolean required
    Whether or not to listen to failed transactions on chain.
  • coin string
    A cryptocurrency or token ticker symbol.
  • label string
    Label of the new webhook.
  • walletId string
  • enterpriseId string
  • organizationId string

    matches ^[0-9a-f]{32}$

  • userId string
  • type string enum
    Event type to listen to.
    bankAccountaccessTokenpolicyBalanceChangereversal
  • numConfirmations number
  • lastAttempt string date-time
  • failingSince string date-time
  • allToken boolean
  • txRequestStates array of string enums
    pendingApprovalcanceledrejectedinitializedpendingDeliverydeliveredpendingUserSignaturependingUserCommitmentpendingUserRSharependingUserGSharereadyToSendsignedfailed
  • txRequestTransactionStates array of string enums
    initializedpendingSignatureeddsaPendingCommitmenteddsaPendingRShareeddsaPendingGShareecdsaMPCv2Round1ecdsaMPCv2Round2ecdsaMPCv2Round3eddsaMPCv2Round1eddsaMPCv2Round2eddsaMPCv2Round3readyToCombineSharessignedhelddeliveredinvalidSignaturerejected
400
Bad Request

Response Body

object

  • name string
    Error code
  • context map of objects required
    Properties that apply to a specific error name
    context object
    • <key> object
  • error string required
    Human-readable error message
  • requestId string required
    Client request id
401
Unauthorized

Response Body

object

  • name string
    Error code
  • context map of objects required
    Properties that apply to a specific error name
    context object
    • <key> object
  • error string required
    Human-readable error message
  • requestId string required
    Client request id
403
Forbidden

Response Body

object

  • name string
    Error code
  • context map of objects required
    Properties that apply to a specific error name
    context object
    • <key> object
  • error string required
    Human-readable error message
  • requestId string required
    Client request id
404
Not Found

Response Body

object

  • name string
    Error code
  • context map of objects required
    Properties that apply to a specific error name
    context object
    • <key> object
  • error string required
    Human-readable error message
  • requestId string required
    Client request id
500
Internal Server Error

Response Body

object

  • name string
    Error code
  • context map of objects required
    Properties that apply to a specific error name
    context object
    • <key> object
  • error string required
    Human-readable error message
  • requestId string required
    Client request id