Create a new contract template (ABI, bytecode, metadata).
curl --request POST \
--url https://sandbox.oumla.com/api/v1/contract-templates \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--header 'x-sdk-version: <x-sdk-version>' \
--data '
{
"name": "<string>",
"description": "<string>",
"bytecode": "<string>",
"abi": [
{
"type": "function",
"inputs": [
{
"name": "<string>",
"type": "<string>",
"value": {},
"description": "<string>",
"internalType": "<string>",
"components": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>",
"internalType": "<string>"
}
],
"indexed": true
}
],
"name": "<string>",
"stateMutability": "pure",
"outputs": [
{
"name": "<string>",
"type": "<string>",
"value": {},
"description": "<string>",
"internalType": "<string>",
"components": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>",
"internalType": "<string>"
}
],
"indexed": true
}
],
"description": "<string>",
"anonymous": true
}
],
"longDescription": "<string>",
"sourceCode": "<string>",
"type": "<string>",
"attributes": {
"useCases": [
"<string>"
],
"standards": [
"<string>"
]
}
}
'{
"contract": {
"id": "<string>",
"name": "<string>",
"description": "<string>",
"longDescription": "<string>",
"bytecode": "<string>",
"sourceCode": "<string>",
"type": "<string>",
"docs": {}
}
}API key for authentication
SDK version header
Contract template created
Show child attributes
Was this page helpful?
curl --request POST \
--url https://sandbox.oumla.com/api/v1/contract-templates \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--header 'x-sdk-version: <x-sdk-version>' \
--data '
{
"name": "<string>",
"description": "<string>",
"bytecode": "<string>",
"abi": [
{
"type": "function",
"inputs": [
{
"name": "<string>",
"type": "<string>",
"value": {},
"description": "<string>",
"internalType": "<string>",
"components": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>",
"internalType": "<string>"
}
],
"indexed": true
}
],
"name": "<string>",
"stateMutability": "pure",
"outputs": [
{
"name": "<string>",
"type": "<string>",
"value": {},
"description": "<string>",
"internalType": "<string>",
"components": [
{
"name": "<string>",
"type": "<string>",
"description": "<string>",
"internalType": "<string>"
}
],
"indexed": true
}
],
"description": "<string>",
"anonymous": true
}
],
"longDescription": "<string>",
"sourceCode": "<string>",
"type": "<string>",
"attributes": {
"useCases": [
"<string>"
],
"standards": [
"<string>"
]
}
}
'{
"contract": {
"id": "<string>",
"name": "<string>",
"description": "<string>",
"longDescription": "<string>",
"bytecode": "<string>",
"sourceCode": "<string>",
"type": "<string>",
"docs": {}
}
}