Skip to main content
GET
/
instructions
/
all
cURL
curl --request GET \
  --url https://api.otim.com/instructions/all \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "address": "0xa0Ee7A142d267C1f36714E4a8F75612F20a79720"
}'
[
  {
    "action": "0x4AA3Bce8f633d68CfC066f7B7DB78443BCFe1B95",
    "arguments": "0x000000000000000000000000aa8e23fb1079ea71e0a56f48a2aa51851d8433d000000000000000000000000070997970c51812dc3a010c7d01b50e0d17dc79c8000000000000000000000000f39fd6e51aad88f6f4ce6ab8827279cfffb922660000000000000000000000000000000000000000000000000000000000000000000000000000000000000000aa8e23fb1079ea71e0a56f48a2aa51851d8433d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000124f8000000000000000000000000000000000000000000000000000000000000186a0",
    "executionState": {
      "executionCounter": 0,
      "executionStatus": "Deactivated",
      "lastExecuted": 0
    },
    "instructedTokenAddress": "0xaA8E23Fb1079EA71e0a56F48a2aA51851D8433D0",
    "instructionId": "0xc73545bc9fa857226b7861a284760b99a0ada92f3ce17f5696fb044ae876da19",
    "lastInstructedValue": "0",
    "maxExecutions": 2,
    "nickname": "test sweep 4",
    "salt": 8433467124545817,
    "totalInstructedValue": "0",
    "chainId": 11155111,
    "chain": "sepolia",
    "lastErrorCode": 0,
    "lastErrorMessage": "Insufficient funds",
    "isDeactivation": false
  }
]

Authorizations

Authorization
string
header
required

JWT token for API authentication

Body

application/json
address
string<address>
required

Address of the user

Example:

"0xa0Ee7A142d267C1f36714E4a8F75612F20a79720"

Response

200 - application/json

Instructions retrieved successfully

action
string<address>

Action contract address

Example:

"0x4AA3Bce8f633d68CfC066f7B7DB78443BCFe1B95"

arguments
string<bytes>

Arguments to execute on the action contract

Example:

"0x000000000000000000000000aa8e23fb1079ea71e0a56f48a2aa51851d8433d000000000000000000000000070997970c51812dc3a010c7d01b50e0d17dc79c8000000000000000000000000f39fd6e51aad88f6f4ce6ab8827279cfffb922660000000000000000000000000000000000000000000000000000000000000000000000000000000000000000aa8e23fb1079ea71e0a56f48a2aa51851d8433d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000124f8000000000000000000000000000000000000000000000000000000000000186a0"

executionState
object
instructedTokenAddress
string<address>

Address of the instructed token

Example:

"0xaA8E23Fb1079EA71e0a56F48a2aA51851D8433D0"

instructionId
string<bytes32>

Unique identifier for the instruction

Example:

"0xc73545bc9fa857226b7861a284760b99a0ada92f3ce17f5696fb044ae876da19"

lastInstructedValue
string

Last instructed value

Example:

"0"

maxExecutions
integer

Maximum number of times this instruction can be executed

Example:

2

nickname
string

Nickname for the instruction

Example:

"test sweep 4"

salt
integer

Salt to ensure instruction is unique

Example:

8433467124545817

totalInstructedValue
string

Total instructed value

Example:

"0"

chainId
integer

Chain ID where the instruction exists

Example:

11155111

chain
string

Name of the chain where the instruction exists

Example:

"sepolia"

lastErrorCode
integer

Code from the last execution error

Example:

0

lastErrorMessage
string | null

Message from the last execution error

Example:

"Insufficient funds"

isDeactivation
boolean

Whether this is a deactivation instruction

Example:

false