Contracts

Get same contracts

Returns contracts which have the same script as the specified one. Note, contract scripts are compared by 32-bit hash, so in very rare cases there may be collisions.

get/v1/contracts/{address}/same

Path parameters

addressstring required

Contract address (starting with KT)

Query parameters

ascstring nullable

Ascending sort mode (optional, i.e. sort.asc=id is the same as sort=id).
Specify a field name to sort by.

Example: ?sort=balance.

descstring nullable

Descending sort mode.
Specify a field name to sort by descending.

Example: ?sort.desc=id.

Sorts items (asc or desc) by the specified field. You can see what fields can be used for sorting in the response description, below.
Click on the parameter to expand more details.

elinteger nullable

Elements offset mode (optional, i.e. offset.el=123 is the same as offset=123).
Skips specified number of elements.

Example: ?offset=100.

pginteger nullable

Page offset mode.
Skips page * limit elements. This is a classic pagination.

Example: ?offset.pg=1.

crinteger nullable

Cursor offset mode.
Skips all elements with the cursor before (including) the specified value. Cursor is a field used for sorting, e.g. id. Avoid using this offset mode with non-unique or non-sequential cursors such as amount, balance, etc.

Example: ?offset.cr=45837.

Specifies which or how many items should be skipped.
Click on the parameter to expand more details.

limitinteger

Maximum number of items to return.

fieldsstring[] nullable

Fields selection mode (optional, i.e. select.fields=balance is the same as select=balance).
Specify a comma-separated list of fields to include into response.

Example: ?select=address,balance as b,metadata.name as meta_name will result in [ { "address": "asd", "b": 10, "meta_name": "qwe" } ].

valuesstring[] nullable

Values selection mode.
Specify a comma-separated list of fields to include their values into response.

Example: ?select.values=address,balance,metadata.name will result in [ [ "asd", 10, "qwe" ] ].

Specify a comma-separated list of fields to include into response or leave it undefined to get default set of fields. This parameter accepts values of the following format: {field}{path?}{as alias?}, so you can do deep selection (for example, ?select=balance,token.metadata.symbol as token,...).
Note, if you select just one field, the response will be flatten into a simple array of values.
Click on the parameter to expand the details.

includeStorageboolean

Specifies whether to include contract storage value in response.

Response

idinteger

Internal TzKT id.
[sortable]

typestring

Type of the account, contract - smart contract programmable account.

addressstring required

Public key hash of the contract

kindstring required

Kind of the contract (delegator_contract or smart_contract), where delegator_contract - manager.tz smart contract for delegation purpose only.

tzipsstring[] nullable

List of implemented standards (TZIPs).

aliasstring nullable

Name of the project behind the contract or contract description.

balanceinteger

Contract balance (micro tez).
[sortable]

delegationLevelinteger nullable

Block height of latest delegation. null if it's not delegated.

delegationTimestring date-time nullable

Block datetime of latest delegation (ISO 8601, e.g. 2020-02-20T02:40:57Z). null if it's not delegated.

numContractsinteger

Number of contracts, created (originated) and/or managed by the contract.

tokensCountinteger

Number of tokens minted in the contract.

activeTokensCountinteger

Number of account tokens with non-zero balances.

tokenBalancesCountinteger

Number of tokens the account ever had.

tokenTransfersCountinteger

Number of token transfers from/to the account.

ticketsCountinteger

Number of tickets minted in the contract.

activeTicketsCountinteger

Number of tickets the account owns.

ticketBalancesCountinteger

Number of tickets the account ever owned.

ticketTransfersCountinteger

Number of ticket transfers from/to the account.

numDelegationsinteger

Number of delegation operations of the contract.

numOriginationsinteger

Number of origination (deployment / contract creation) operations, related the contract.

numTransactionsinteger

Number of transaction (transfer) operations, related to the contract.
[sortable]

numRevealsinteger

Number of reveal (is used to reveal the public key associated with an account) operations of the contract.

numMigrationsinteger

Number of migration (result of the context (database) migration during a protocol update) operations. related to the contract (synthetic type).

transferTicketCountinteger

Number of transfer ticket operations related to the contract.

increasePaidStorageCountinteger

Number of increase_paid_storage operations related to the contract.

eventsCountinteger

Number of events produced by the contract.

firstActivityinteger

Block height of the contract creation.
[sortable]

firstActivityTimestring date-time

Block datetime of the contract creation (ISO 8601, e.g. 2020-02-20T02:40:57Z).

lastActivityinteger

Height of the block in which the account state was changed last time.
[sortable]

lastActivityTimestring date-time

Datetime of the block in which the account state was changed last time (ISO 8601, e.g. 2020-02-20T02:40:57Z).

typeHashinteger

32-bit hash of the contract parameter and storage types. This field can be used for searching similar contracts (which have the same interface).

codeHashinteger

32-bit hash of the contract code. This field can be used for searching same contracts (which have the same script).

{"stackTrail":"components:schemas:Contract:allOf:properties:metadata","oasType":"schema","type":"unknown","description":"TZIP-16 metadata.","nullable":true}
{"stackTrail":"components:schemas:Contract:allOf:properties:extras","oasType":"schema","type":"unknown","description":"Off-chain extras.","nullable":true}
{"stackTrail":"components:schemas:Contract:allOf:properties:storage","oasType":"schema","type":"unknown","description":"Contract storage value. Omitted by default. Use `?includeStorage=true` to include it into response.","nullable":true}

Changes

No recorded changes to this endpoint across all 1 revision of this API.