POST
/
admin
/
contract
/
authorizeWithJSONABI
curl --request POST \
  --url https://api.syndicate.io/admin/contract/authorizeWithJSONABI \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "chainId": 80001,
  "address": "0x94f6E9c420Db1566A3c035Df291F206eBfAfC762",
  "name": "My Contract",
  "projectId": "638d1d78-d63d-4cda-9f1e-4d0799acfeee",
  "abi": [
    {
      "type": "function",
      "name": "addPerson",
      "constant": false,
      "payable": false,
      "inputs": [
        {
          "type": "tuple",
          "name": "person",
          "components": [
            {
              "type": "string",
              "name": "name"
            },
            {
              "type": "uint16",
              "name": "age"
            }
          ]
        }
      ],
      "outputs": []
    }
  ]
}'
{
  "id": "70c2891a-6471-4b50-844b-6a58b69ff8fb",
  "createdAt": "2023-10-25T13:00:49.667604Z",
  "updatedAt": "2023-10-25T13:00:49.667604Z",
  "projectId": "638d1d78-d63d-4cda-9f1e-4d0799acfeee",
  "chainId": 80001,
  "address": "0x94f6E9c420Db1566A3c035Df291F206eBfAfC762",
  "name": "My Contract",
  "functionSignatures": [
    {
      "id": "4416002f-6b79-4c24-b367-80572c37f35a",
      "createdAt": "2023-10-25T13:00:49.667604Z",
      "signature": "addPerson((string name, uint16 age) person))",
      "functionAbi": {
        "type": "function",
        "name": "addPerson",
        "inputs": [
          {
            "name": "person",
            "type": "tuple",
            "components": [
              {
                "name": "name",
                "type": "string"
              },
              {
                "name": "age",
                "type": "uint16"
              }
            ]
          }
        ],
        "stateMutability": "nonpayable"
      },
      "hashedSignature": "0x1234",
      "contractId": "70c2891a-6471-4b50-844b-6a58b69ff8fb",
      "payable": false
    }
  ]
}

API Endpoint

https://api.syndicate.io/admin/contract/authorizeWithJSONABI

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
chainId
integer
required
address
string
required
name
string
required
projectId
string
required
expiresAt
string | null
abi
any[]
required

Response

200 - application/json
id
string
required
createdAt
string
required
updatedAt
string | null
chainId
integer
required
address
string
required
name
string
required
expiresAt
string | null
functionSignatures
object[]
required
projectId
string
required
claimedByOrganizationId
string | null