Skip to content

Remove Admin from a Moment

This page documents the API endpoint for removing admin permissions from a Moment on the In Process protocol. This endpoint allows artists to revoke admin permissions from addresses that were previously granted admin access to their Moments.

Note: Only the current Moment admin can remove permissions from other addresses. The transaction is executed via a smart account using Coinbase CDP.

Endpoint

DELETE https://inprocess.world/api/moment/permission

Authentication

Include an API key in the x-api-key header for authorization:

x-api-key: <artist_api_key>
Show more

See Create an Artist API Key for how to create API keys.

Request Body

Send a JSON object with the following fields:

{
  "moment": {
    "collectionAddress": "string", // Contract address of the Moment
    "tokenId": "string", // Token ID of the Moment
    "chainId": number // Chain ID (optional, default: Base 8453)
  },
  "adminAddress": "string" // Address to revoke admin permissions from
}

Body Parameters

NameTypeRequiredDescription
momentobjectYesObject containing the Moment identifier
moment.collectionAddressstringYesThe contract address of the Moment
moment.tokenIdstringYesThe token ID of the Moment
moment.chainIdnumberNoThe Chain ID of the Moment (optional, default: Base 8453)
adminAddressstringYesThe address to revoke admin permissions from

Example Requests

cURL
curl -X DELETE https://inprocess.world/api/moment/permission \
  -H "Content-Type: application/json" \
  -H "x-api-key: art_sk_3fnm4...f6w4" \
  -d '{
    "moment": {
      "collectionAddress": "0x297F21AAc502571db2c7dBFD271E68Dae7F2cE1E",
      "tokenId": "1"
    },
    "adminAddress": "0x119A62232b96ADfC85E40C57fE44acA740CF6730"
  }'

Example Response

{
  "hash": "0xTransactionHash",
  "chainId": 8453
}

Response Properties

PropertyTypeDescription
hashstringThe transaction hash of the permission update
chainIdnumberThe chain ID where the transaction was executed

How It Works

This endpoint revokes admin permissions (permission bit 2) from the specified address for the given Moment. The permission is removed onchain via the Collection contract's removePermission function.

Key points:
  • The transaction is executed using a smart account via Coinbase CDP
  • The artist address from the API key is used as the signer
  • Admin permissions are revoked from the specified address, removing their ability to manage the Moment (e.g., update URI, set sales config, etc.)
  • Only existing Moment admins can remove permissions from other addresses

Error Responses

400 Bad Request

Invalid request parameters:

{
  "error": "Invalid query parameters",
  "errors": [
    {
      "field": "moment.collectionAddress",
      "message": "Invalid address"
    }
  ]
}

500 Internal Server Error

{
  "error": "Failed to remove permission"
}