githubEdit

Api Reference

Get turret information

get

Returns basic information about the turret

Responses
chevron-right
200

Success

application/json
turretstringOptional

The public key of the turret owner

Example: GB4OYM7TQTJSROWXHOJLKAX2IJ2QN4I6S6GCJH4MGWVTAO5Q5DPNADXX
networkstringOptional

The Stellar Network the turret is on. TESTNET or PUBLIC

Example: TESTNET
horizonstringOptional

The Horizon API the turret uses

Example: https://horizon-testnet.stellar.org
versionstringOptional

The repository version and last commit

Example: v0.0.0-ff9e9750369cc8aed29af9f08ae34634594cbe41
get
/
200

Success

Upload a txFunction

post

Uploads a txFunction to the turret.

Body
txFunctionstringOptional

The source code to be uploaded

Example: /some/path/txFunction.js
txFunctionFieldsstringOptional

A Base64 encoded array of json object of the input fields for the contract in this format:


[
{
"name": "paramName",
"type": "string",
"description": "This is a param",
"rule": "Required"
}
]

Valid rules are Required and Optional

Example: W3sibmFtZSI6ImRlc3RpbmF0aW9uIiwidHlwZSI6InN0cmluZyIsImRlc2NyaXB0aW9uIjoiU3RlbGxhciBwdWJsaWMga2V5IHlvdSdkIGxpa2UgdG8gcGF5IiwicnVsZSI6Ik11c3QgYmUgYSB2YWxpZCBhbmQgZnVuZGVkIFN0ZWxsYXIgcHVibGljIGtleSJ9XQ
txFunctionFeestringOptional

A signed, non-submitted transaction envelope XDR for a fee payment to the TURRET_ADDRESS that is greater than or equal to the byte length of the contract divided by the UPLOAD_DIVISOR set by the turret

Example: AAAAAgAAAABTqjFHz0quLSka8SOrkw7R07aqDNUHAe+Qm5PX0jMiGwAAAGQAHfBZAAAADgAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAB47DPzhNMoutc7krUC+kJ1BvEel4wkn4w1qzA7sOje0AAAAAAAAAAAAJiWgAAAAAAAAAAB0jMiGwAAAEAZjWTnxXY2lxVt0VSos6/Uvpoo3pXo6l+0Xk/P+sE5KDPwhAYkVQyXEBb8prEYprzp3aSlLF4TKcw3m/RM5IMK
Responses
chevron-right
200

txFunction uploaded

application/json
hashstringOptional

The SHA256 hash value of the contract

Example: 78565516a844fd4dfc5a7fc7da822028b04ee0aeaf981a4a914d4510906a7a32
signerstringOptional

The public key of the signer the turret will use to sign the uploaded contract

Example: GB6VNMGXKHS4UTIXW7U23ZQFWD7UJIWCJNQZR7ISNKBTYNULCFQKKPIK
post
/tx-functions

Send a fee payment to the turret

post

Sends a fee payment to the turret

Path parameters
publicKeystringRequired

The Stellar public address of the account to apply the fee payment to

Body
txFunctionFeestringOptional

A signed, non-submitted transaction envelope XDR for a fee payment to the TURRET_ADDRESS that is greater than or equal to the byte length of the contract divided by the UPLOAD_DIVISOR set by the turret

Example: AAAAAgAAAABTqjFHz0quLSka8SOrkw7R07aqDNUHAe+Qm5PX0jMiGwAAAGQAHfBZAAAADgAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAQAAAAB47DPzhNMoutc7krUC+kJ1BvEel4wkn4w1qzA7sOje0AAAAAAAAAAAAJiWgAAAAAAAAAAB0jMiGwAAAEAZjWTnxXY2lxVt0VSos6/Uvpoo3pXo6l+0Xk/P+sE5KDPwhAYkVQyXEBb8prEYprzp3aSlLF4TKcw3m/RM5IMK
Responses
chevron-right
200

Fee payment applied

application/json
publicKeystringOptional

The public key of the Stellar account that owns the fees

Example: GB6VNMGXKHS4UTIXW7U23ZQFWD7UJIWCJNQZR7ISNKBTYNULCFQKKPIK
lastModifiedTimenumberOptional

The epoch timestamp in milliseconds of the last time the fee balance modified

Example: 1631468533000
balancestringOptional

The current fee balance in XLM

Example: 1.4234001
post
/tx-fees/{publicKey}

Last updated