Skip to main content
POST
/
v0
/
cosmos
/
transaction
/
scan
Scan Transaction
curl --request POST \
  --url https://api.blockaid.io/v0/cosmos/transaction/scan \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "chain": "osmosis",
  "options": [
    "validation",
    "simulation"
  ],
  "metadata": {
    "type": "in_app"
  },
  "account_address": "osmo1gu92w3wkwawq6q8epdsyce6x7q5gzvv528l74c",
  "transaction": "CqwCCqkCCh0vY29zbW9zLmF1dGh6LnYxYmV0YTEuTXNnRXhlYxKHAgorb3NtbzFudGEza3VjbmN1Z3JwMmYzbHE2ejd5bTc0cHRyZHBjazNtaGRxdRLXAQoeL2Nvc21vcy5hdXRoei52MWJldGExLk1zZ0dyYW50ErQBCitvc21vMWd1OTJ3M3drd2F3cTZxOGVwZHN5Y2U2eDdxNWd6dnY1MjhsNzRjEitvc21vMWFwM2U4NWU5dHg0dW15OXc0czU1OXllZ3pzN3k0d2NqdDdzM2V1GlgKTgoqL2Nvc21vcy5hdXRoei52MWJldGExLkdlbmVyaWNBdXRob3JpemF0aW9uEiAKHi9jb3Ntb3MuYXV0aHoudjFiZXRhMS5Nc2dHcmFudBIGCIm2nYgHEmcKUApGCh8vY29zbW9zLmNyeXB0by5zZWNwMjU2azEuUHViS2V5EiMKIQKSsVCOfTcKsI0EBMkVgXx4F8snmhMP5UhQI4WMs0oCAxIECgIIARgBEhMKDQoFdW9zbW8SBDI0OTUQyNAIGkC83oeXc4fSOH44gBJBfRQaBFISNhY8hmlAxYJY645LT0iIYhTZ4YgKZx5D5PgSGqKlrGd6PC3SbnTxcFSUcpF7"
}
'
{
  "simulation": {
    "status": "Success",
    "assets_diffs": {},
    "address_details": {},
    "exposures": {},
    "authorizations": {},
    "account_summary": {
      "assets_diffs": [
        {
          "asset": {
            "type": "BankToken",
            "name": "<string>",
            "logo": "<string>",
            "address": "<string>",
            "symbol": "<string>",
            "decimal": "<string>"
          },
          "in": [
            {
              "usd_price": "<any>",
              "summary": "<any>",
              "value": "<any>",
              "raw_value": "<any>"
            }
          ],
          "out": [
            {
              "usd_price": "<any>",
              "summary": "<any>",
              "value": "<any>",
              "raw_value": "<any>"
            }
          ]
        }
      ],
      "total_usd_diff": {
        "in": "<string>",
        "out": "<string>",
        "total": "<string>"
      },
      "exposures": [
        {
          "asset": {
            "type": "BankToken",
            "name": "<string>",
            "logo": "<string>",
            "address": "<string>",
            "symbol": "<string>",
            "decimal": "<string>"
          },
          "spenders": {}
        }
      ],
      "authorizations": [
        {
          "authorize_to": "<string>",
          "granted_authorizations": [
            {
              "type": "<any>",
              "description": "<any>"
            }
          ],
          "revoked_authorizations": [
            {
              "type": "<any>",
              "description": "<any>"
            }
          ]
        }
      ],
      "total_usd_exposure": {}
    }
  },
  "validation": {
    "status": "Success",
    "result_type": "Malicious",
    "description": "<string>",
    "classification": "<string>",
    "reason": "losing_assets",
    "features": [
      {
        "type": "Malicious",
        "feature_id": "<string>",
        "description": "<string>",
        "address": "<string>"
      }
    ]
  },
  "events": [
    {
      "type": "<string>",
      "attributes": [
        {
          "key": "<string>",
          "value": "<string>"
        }
      ],
      "message_index": 123
    }
  ],
  "gas_estimation": {
    "status": "Success",
    "gas_wanted": 123,
    "gas_used": 123
  },
  "account_address": "<string>",
  "chain": "cosmos"
}

Authorizations

X-API-Key
string
header
required

Body

application/json
chain
enum<string>
required

The chain's name or identifier

Available options:
cosmos,
osmosis
Examples:

"osmosis"

metadata
object
required

Metadata

transaction
string
required

The transaction bytes encoded as base64

Examples:

"CqwCCqkCCh0vY29zbW9zLmF1dGh6LnYxYmV0YTEuTXNnRXhlYxKHAgorb3NtbzFudGEza3VjbmN1Z3JwMmYzbHE2ejd5bTc0cHRyZHBjazNtaGRxdRLXAQoeL2Nvc21vcy5hdXRoei52MWJldGExLk1zZ0dyYW50ErQBCitvc21vMWd1OTJ3M3drd2F3cTZxOGVwZHN5Y2U2eDdxNWd6dnY1MjhsNzRjEitvc21vMWFwM2U4NWU5dHg0dW15OXc0czU1OXllZ3pzN3k0d2NqdDdzM2V1GlgKTgoqL2Nvc21vcy5hdXRoei52MWJldGExLkdlbmVyaWNBdXRob3JpemF0aW9uEiAKHi9jb3Ntb3MuYXV0aHoudjFiZXRhMS5Nc2dHcmFudBIGCIm2nYgHEmcKUApGCh8vY29zbW9zLmNyeXB0by5zZWNwMjU2azEuUHViS2V5EiMKIQKSsVCOfTcKsI0EBMkVgXx4F8snmhMP5UhQI4WMs0oCAxIECgIIARgBEhMKDQoFdW9zbW8SBDI0OTUQyNAIGkC83oeXc4fSOH44gBJBfRQaBFISNhY8hmlAxYJY645LT0iIYhTZ4YgKZx5D5PgSGqKlrGd6PC3SbnTxcFSUcpF7"

options
enum<string>[]

List of options to include in the response

  • simulation: Include simulation output in the response
  • validation: Include security validation of the transaction in the response
  • events: Include emitted events of the transaction in the response
  • gas_estimation: Include gas estimation of the transaction in the response
Minimum length: 1
Examples:
["validation", "simulation"]
account_address
string | null

Address of the account signing the transaction

Examples:

"osmo1gu92w3wkwawq6q8epdsyce6x7q5gzvv528l74c"

Response

Successful Response

chain
enum<string>
required
Available options:
cosmos,
osmosis
simulation
object

Simulation result; Only present if simulation option is included in the request

validation
object

Validation result; Only present if validation option is included in the request

events
CosmosEventSchema · object[] | null

A list of events emitted from the transaction

gas_estimation
object

Gas estimation for the transaction

account_address
string | null

The account signing the transaction