REST APIPolicyPolicy Builder

GET

Lists all policy rules for an enterprise.

Path Params

  • enterpriseId string required
    Your Enterprise Id.

Query Params

  • createdDateGte string date-time
    The date and time of the earliest policy rule creation to return. The date and time must be in ISO 8601 format.
  • createdDateLte string date-time
    The date and time of the latest policy rule creation to return. The date and time must be in ISO 8601 format.
  • evaluationId string
    The id of the Evaluation.
  • evaluationStatus string enum
    Status of the Evaluation
    TRIGGEREDNOT_TRIGGERED
  • name string
    A string to match the names of the policy rules against.
  • status string enum
    Statuses of the returned policy rules, one or more may be provided.
    PENDINGACTIVEINACTIVEINACTIVE_HIDDENDENIEDPENDING_APPROVALUNLOCK_PENDING
  • scopes string enum
    scopes of the returned policy rules. One or more may be provided. For example, the All Wallets scope. See also the List scopes API.
    wallet.segregatedpolicies.management
  • touchpoints string
    The Touchpoints of the returned policy rules. One or more may be provided. For example, the Transfer from a Wallet Touchpoint. See also the List scope Touchpoints API.
  • id string
    Id of the policy rule.
  • limit integer
    How many policy rules to return per page of results. Default: 20, Maximum: 100.
  • prevId integer
    The nextBatchPrevId returned by the last call to the same API. Used to retrieve the next page of results.
  • filteringConditionParameterName string

    You can retrieve the policy rules that match a given set of Filtering Conditions by providing the parameter name and value of the Filtering Conditions you are interested in. See also Filtering Conditions. In addition, you could add Dynamic parameter for filtering rules based on specific criteria. Format:

    ..parameters.=

    : (Required) The table name. Valid values are filteringCondition, action, or condition.
  • : (Optional) The name of the property.
  • parameters: (Fixed) Indicates parameters section.
  • : (Required) The key in the table's parameters column to search against.
  • : (Optional) Comma-separated list of values to match.
  • Responses

    200
    Paginated list of policy rules.

    Response Body

    object

    Paginated list of Policy Rules.
    • nextBatchPrevId string required
      The value to pass as the prevId to the API for getting the next page.
    • rules array of objects
      A list of Policy Rules matching the search criteria.
      rules object
      • id string required
        Id of the Policy Rule. This identifier is not unique in isolation, it must be paired with an specific Policy Rule Version number to uniquely identified a particular version of a Policy Rule. A UUID.
      • uniqueId string required
        The uniqueId of the Policy Rule version. A UUID.
      • name string required
        Human readable name of the rule.
      • status string enum required

        Indicates if the Policy Rule is considered in Evaluations.

        • ACTIVE - Will be Evaluated.
        • INACTIVE - Will NOT be Evaluated.
        • DENIED - The requested policy rule change was Denied.
        • PENDING_APPROVAL - This version of the policy rule is Pending Approval before it can be activated.
        • UNLOCK_PENDING - This version of the policy rule is created when a request to unlock a policy is initiated.
        ACTIVEINACTIVEDENIEDPENDING_APPROVALUNLOCK_PENDING
      • version integer
        The Policy Rule Version, an integer that is incremented each time the Policy Rule changes.

        Defaults to 1

      • adminOnly boolean required
        true, if the Policy Rule is a BitGo internal rule. Typically, this allows setting Global Policy Rules across enterprises.
      • touchpointId string required
        The id of the Touchpoint associated with the Policy Rule. A UUID.
      • touchpointLabel string required
        Label of the Touchpoint associated with the Policy Rule. For example the Transfer from a Wallet Touchpoint.
      • scopeId string required
        The id of the Scope associated with the Policy Rule. A UUID.
      • scopeLabel string required
        Label of the Scope associated with the Policy Rule. For example the All Wallets Scope.
      • clauses array of objects required
        List of Policy Rule Clauses: a combination of Conditions and Actions.
        clauses object
        • actions array of objects

          ANY OF

          • name string enum required
            Name of the associated Action.
            approvals.always.deny
        • conditions array of objects

          ANY OF

          • name string enum required
            Name of the condition.
            transfer.amount
          • parameters object required
            Data required to evaluate the condition.
            parameters object
            • operator string enum required
              The comparison operator to use when comparing the transfer amount with the given limit
              >>=<<=
            • amount string required
              The transfer amount is compared with this limit.
            • coin string required
              This condition only applies to transfers of this currency (USD applies to all transfers).
          • operator string enum
            Boolean operators that join Conditions, and/or Actions. Must be null on the last Condition or Action, or if there is only one Condition or Action, must be non-null on all others.
            ANDOR
      • filteringConditions array of objects required
        List of Filtering Conditions that must trigger for this Policy Rule to be Evaluated.

        ANY OF

        • name string enum required
          Name of the condition.
          wallet.type
        • parameters object required
          Required data needed to evaluate the Filtering Condition.
          parameters object
          • walletType array of string enums required
            hotcustodialtrading
      • locked boolean required
        true, if the Policy Rule is locked, false otherwise.
      • lockType string enum required

        Indicates how the Policy Rule is locked.

        • LOCK_AFTER_DATE - Will lock after the lockDate set on the Policy Rule.
        • PERMANENT - Is permanently locked.
        LOCK_AFTER_DATEPERMANENT
      • lockDate string date-time
        The date after which the Policy Rule will be locked. Only applicable if the Policy Rule is locked with LOCK_AFTER_DATE.
      • enterpriseId string
        The id of the Enterprise this Policy Rule belongs to.
      • organizationId string
        The id of the Organization this Policy Rule belongs to.
      • lastTriggeredDate string date-time
        The date when the Policy Rule was last triggered. Only applicable if the Policy Rule is locked with LOCK_AFTER_DATE.
      • lastTriggeredEvaluationId string
        The id of the Evaluation that last triggered the Policy Rule. A UUID.
      • createdBy string required
        The id of the user who created the Policy Rule or the string "BitGo".
      • modifiedBy string required
        The id of the user who last modified the Policy Rule or the string "BitGo".
      • createdDate string date-time required
        The date when the Policy Rule was created. A timestamp.
      • modifiedDate string date-time required
        The date when the Policy Rule was last modified. A timestamp.
      • lockModifiedBy string
        The id of the user who last modified the lock of the Policy Rule.
      • evaluationId string
        The id of the Evaluation that was done when this Policy Rule version was requested to be created, modified or deleted. A UUID.
    401
    Unauthorized

    Response Body

    object

    • code string
    • message string
    • status integer
    403
    Forbidden

    Response Body

    object

    • code string
    • message string
    • status integer
    404
    The specified resource was not found

    Response Body

    object

    • code string
    • message string
    • status integer
    500
    Server Error - Transient error please try again

    Response Body

    object

    • code string
    • message string
    • status integer