PUT
Update policy rule
Updates a policy rule, resulting in a new version number that's equal to the highest existing version plus 1. The ID of the policy rule remains the unchanged.
Path Params
-
enterpriseIdstring requiredYour Enterprise Id. -
touchpointNamestring requiredThe name of the Touchpoint. -
idstring requiredId of the policy rule.
Body Params
object
Create or Update policy rule Request.
-
namestring requiredHuman readable name of the rule. -
adminOnlybooleantrue, if the policy rule is a BitGo internal rule, false otherwise. -
clausesarray of objects requiredList of policy rule Clauses: a combination of Conditions and Actions.clauses object
-
conditionsarray of objects requiredANY OF
- TransferAmountConditionRequest
- TransferVelocityLimitConditionRequest
- TransferDestinationTypeConditionRequest
- TransferInitiatorsConditionRequest
- TransferWebhookConditionRequest
- TransferNotInitiatedByConditionRequest
No matching variants
-
namestring enum requiredName of the condition.transfer.amount -
parametersobject requiredData required to evaluate the condition.parameters object
-
operatorstring enum requiredThe comparison operator to use when comparing the transfer amount with the given limit>>=<<= -
amountstring requiredThe transfer amount is compared with this limit. -
coinstring requiredThis condition only applies to transfers of this currency (USD applies to all transfers).
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the condition.transfer.velocity.limit -
parametersobject requiredData required to evaluate the transfer velocity limit condition.parameters object
-
scopestring enum requiredEntities to include in the velocity calculation.walletenterprise -
timeWindowstring requiredA window of time in which a set of amount can be spent. -
amountstring requiredThe transfer amount is compared with this limit. -
coinstring requiredThe unit that the amount is denoted in, in either crypto or a fiat currency.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the condition.transfer.destination.type -
parametersobject requiredData required to evaluate the transfer destination condition.parameters object
-
typestring enum requiredThe type of destination this condition will match.whitelistedAddressnonWhitelistedAddressoutsideEnterprise -
coinstringThe asset this condition applies to.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the condition.transfer.initiators -
parametersobject requiredData required to evaluate the transfer initiator condition.parameters object
-
userIdsarray of strings requiredA list of user IDs to validate for the transfer initiator.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the condition.transfer.webhook -
parametersobject requiredData required to evaluate the transfer webhook condition.parameters object
-
webhookUrlstring requiredThe webhook url to post transfer payload to. -
coinstringThe asset this condition applies to.
-
-
namestring enum requiredName of the associated Condition.transfer.notInitiatedBy -
parametersobject requiredRequired data needed to evaluate the Condition.parameters object
-
userIdsarray of strings requiredList of user IDs
-
-
operatorstring enumBoolean 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
-
actionsarray of objects requiredANY OF
- AlwaysDenyActionRequest
- WalletAdminActionRequest
- FinalApprovalActionRequest
- EnterpriseUsersActionRequest
- EnterpriseAdminsActionRequest
- LivenessVerificationFromEnterpriseAdminActionRequest
- LivenessVerificationFromRequestorActionRequest
- LivenessVerificationFromEnterpriseUsersActionRequest
- NoneActionRequest
- VideoApprovalActionRequest
- IdVerificationActionRequest
- OrganizationAdminActionRequest
No matching variants
-
namestring enum requiredName of the associated Action.approvals.always.deny
-
namestring enum requiredName of the associated Action.approvals.customer.walletAdmin -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
minRequiredstring requiredNumber of required approvals
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.customer.finalApproval -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
userIdsarray of strings requiredThe final approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. true by default.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.customer.enterpriseUser -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
userIdsarray of strings requiredList of enterprise users for approval -
minRequirednumber requiredMinimum required number of approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. false by default.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.customer.enterpriseAdmin -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
minRequirednumber requiredMinimum required number of approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. false by default.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.bitgo.livenessVerificationFromEnterpriseAdmins -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
minRequirednumber requiredMinimum required number of approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. false by default.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.bitgo.livenessVerificationFromRequestor -
parametersobjectRequired data needed to configure the Action.parameters object
-
minRequirednumberMinimum required number of approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. false by default.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.bitgo.livenessVerificationFromUsers -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
userIdsarray of strings requiredList of enterprise users for approval -
minRequirednumber requiredMinimum required number of approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. false by default.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.bitgo.noop -
parametersmapRequired data needed to configure the Action. -
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.bitgo.videoApproval -
parametersobject requiredRequired data needed to configure the Action. -
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.bitgo.idVerification -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
isFallbackbooleanWhether this is a fallback action.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.customer.organizationAdmin -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
minRequiredstring requiredMinimum required number of approvers
-
-
operatorstring enumBoolean 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
-
-
filteringConditionsarray of objects requiredList of Filtering Conditions that must trigger for the policy rule to be Evaluated.ANY OF
-
namestring enum requiredName of the condition.wallet.ids -
parametersobject requiredRequired data needed to evaluate the Filtering Condition.parameters object
-
walletIdarray of strings required
-
-
namestring enum requiredName of the condition.wallet.type -
parametersobject requiredRequired data needed to evaluate the Filtering Condition.parameters object
-
walletTypearray of string enums requiredhotcustodialtrading
-
-
namestring enum requiredName of the condition.wallet.all
-
namestring enum requiredName of the condition.rule.all -
parametersmapRequired data needed to evaluate the Filtering Condition.
-
namestring enum requiredName of the condition.wallet.multiple.ids -
parametersobject requiredRequired data needed to evaluate the Filtering Condition.parameters object
-
walletIdarray of strings required
-
-
-
lockTypestring enumIndicates how the policy rule is locked.
LOCK_AFTER_DATE- Will lock after the lockDate set on the policy rule.PERMANENT- Is permanently locked.NEVER- Is never locked.
LOCK_AFTER_DATEPERMANENTNEVER -
lockDatestring date-timeThe date after which the policy rule will be locked. Only applicable if the policy rule is locked withLOCK_AFTER_DATE.
Responses
201
The updated policy rule
Response Body
object
A Policy Rule, the combination of a Scope, a Touchpoint, Conditions, and Actions. It allows you to define what
needs to happen (Actions) before a user can execute a sensitive operation (Touchpoint) on a Scope (e.g. a Wallet)
depending on the specific details of the operation (Conditions). See Concepts.
-
idstring requiredId 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. -
uniqueIdstring requiredThe uniqueId of the Policy Rule version. A UUID. -
namestring requiredHuman readable name of the rule. -
statusstring enum requiredIndicates 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 -
versionintegerThe Policy Rule Version, an integer that is incremented each time the Policy Rule changes. -
adminOnlyboolean requiredtrue, if the Policy Rule is a BitGo internal rule. Typically, this allows setting Global Policy Rules across enterprises. -
touchpointIdstring requiredThe id of the Touchpoint associated with the Policy Rule. A UUID. -
touchpointLabelstring requiredLabel of the Touchpoint associated with the Policy Rule. For example the Transfer from a Wallet Touchpoint. -
scopeIdstring requiredThe id of the Scope associated with the Policy Rule. A UUID. -
scopeLabelstring requiredLabel of the Scope associated with the Policy Rule. For example the All Wallets Scope. -
clausesarray of objects requiredList of Policy Rule Clauses: a combination of Conditions and Actions.clauses object
-
actionsarray of objectsANY OF
-
namestring enum requiredName of the associated Action.approvals.always.deny
-
namestring enum requiredName of the associated Action.approvals.customer.enterpriseAdmin -
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.customer.walletAdmin -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
minRequiredstring requiredNumber of required approvals
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.customer.finalApproval -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
userIdsarray of strings requiredThe final approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. true by default.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the associated Action.approvals.customer.enterpriseUser -
parametersobject requiredRequired data needed to configure the Action.parameters object
-
userIdsarray of strings requiredList of enterprise users for approval -
minRequirednumber requiredMinimum required number of approvers -
initiatorIsAllowedToApprovebooleanWhether the initiator is allowed to approve this action. false by default.
-
-
operatorstring enumBoolean 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
-
-
conditionsarray of objectsANY OF
-
namestring enum requiredName of the condition.transfer.amount -
parametersobject requiredData required to evaluate the condition.parameters object
-
operatorstring enum requiredThe comparison operator to use when comparing the transfer amount with the given limit>>=<<= -
amountstring requiredThe transfer amount is compared with this limit. -
coinstring requiredThis condition only applies to transfers of this currency (USD applies to all transfers).
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the condition.transfer.velocity.limit -
parametersobject requiredData required to evaluate the transfer velocity limit condition.parameters object
-
scopestring enum requiredEntities to include in the velocity calculation.walletenterprise -
timeWindowstring requiredA window of time in which a set of amount can be spent. -
amountstring requiredThe transfer amount is compared with this limit. -
coinstring requiredThe unit that the amount is denoted in, in either crypto or a fiat currency.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the condition.transfer.destination.type -
parametersobject requiredData required to evaluate the transfer destination condition.parameters object
-
typestring enum requiredThe type of destination this condition will match.whitelistedAddressnonWhitelistedAddressoutsideEnterprise -
coinstringThe asset this condition applies to.
-
-
operatorstring enumBoolean 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
-
namestring enum requiredName of the condition.transfer.initiators -
parametersobject requiredData required to evaluate the transfer initiator condition.parameters object
-
userIdsarray of strings requiredA list of user IDs to validate for the transfer initiator.
-
-
operatorstring enumBoolean 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
-
-
-
filteringConditionsarray of objects requiredList of Filtering Conditions that must trigger for this Policy Rule to be Evaluated.ANY OF
-
namestring enum requiredName of the condition.wallet.type -
parametersobject requiredRequired data needed to evaluate the Filtering Condition.parameters object
-
walletTypearray of string enums requiredhotcustodialtrading
-
-
namestring enum requiredName of the condition.wallet.ids -
parametersobject requiredRequired data needed to evaluate the Filtering Condition.parameters object
-
walletIdarray of strings required
-
-
namestring enum requiredName of the condition.wallet.all
-
namestring enum requiredName of the condition.rule.all -
parametersmapRequired data needed to evaluate the Filtering Condition.
-
namestring enum requiredName of the condition.wallet.multiple.ids -
parametersobject requiredRequired data needed to evaluate the Filtering Condition.parameters object
-
walletIdarray of strings required
-
-
-
lockedboolean requiredtrue, if the Policy Rule is locked, false otherwise. -
lockTypestring enum requiredIndicates 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 -
lockDatestring date-timeThe date after which the Policy Rule will be locked. Only applicable if the Policy Rule is locked withLOCK_AFTER_DATE. -
enterpriseIdstringThe id of the Enterprise this Policy Rule belongs to. -
organizationIdstringThe id of the Organization this Policy Rule belongs to. -
lastTriggeredDatestring date-timeThe date when the Policy Rule was last triggered. Only applicable if the Policy Rule is locked withLOCK_AFTER_DATE. -
lastTriggeredEvaluationIdstringThe id of the Evaluation that last triggered the Policy Rule. A UUID. -
createdBystring requiredThe id of the user who created the Policy Rule or the string "BitGo". -
modifiedBystring requiredThe id of the user who last modified the Policy Rule or the string "BitGo". -
createdDatestring date-time requiredThe date when the Policy Rule was created. A timestamp. -
modifiedDatestring date-time requiredThe date when the Policy Rule was last modified. A timestamp. -
lockModifiedBystringThe id of the user who last modified the lock of the Policy Rule. -
evaluationIdstringThe id of the Evaluation that was done when this Policy Rule version was requested to be created, modified or deleted. A UUID.
400
Bad Request
Response Body
ONE OF
-
codestring -
messagestring -
statusinteger
-
codestring -
messagestring -
statusinteger -
failedValidationsobject
401
Unauthorized
Response Body
object
-
codestring -
messagestring -
statusinteger
403
Forbidden
Response Body
object
-
codestring -
messagestring -
statusinteger
404
The specified resource was not found
Response Body
object
-
codestring -
messagestring -
statusinteger
409
Conflict - The request conflicts with the current state of the resource
Response Body
object
-
codestring -
messagestring -
statusinteger
500
Server Error - Transient error please try again
Response Body
object
-
codestring -
messagestring -
statusinteger