{
  "x402Version": 2,
  "id": 8367,
  "slug": "8367",
  "resource": "https://agent-api-testnet.tim1712.workers.dev/v1/evm/contract-preflight",
  "description": "Inspect a Base smart-contract address before interacting with it. Returns deterministic bytecode hash/size, EIP-1967 implementation information, ERC-20 metadata when available, and the current chain head. Read-only and does not make safety or legitimacy claims.",
  "type": "http",
  "accepts": [
    {
      "scheme": "exact",
      "network": "eip155:84532",
      "payTo": "0x5229384BD502D85aa7EcA0A31B515E5E48d3910F",
      "asset": "0x036CbD53842c5426634e7929541eC2318f3dCF7e",
      "amount": "5000",
      "maxTimeoutSeconds": 300
    }
  ],
  "outputSchema": {
    "bazaar": {
      "info": {
        "input": {
          "body": {
            "address": "0x036CbD53842c5426634e7929541eC2318f3dCF7e"
          },
          "bodyType": "json",
          "method": "POST",
          "type": "http"
        },
        "output": {
          "example": {
            "address": "0x036CbD53842c5426634e7929541eC2318f3dCF7e",
            "chain": {
              "blockNumber": 25000000,
              "headAgeSeconds": 2,
              "headTimestamp": "2026-08-30T10:00:00.000Z"
            },
            "chainId": 84532,
            "checkedAt": "2026-08-30T10:00:02.000Z",
            "codeHash": "0x8e8f23e7f585953f9438e890f6f2c7f4287fef3a543aa48a8f6f547e840f5a87",
            "codeSizeBytes": 492,
            "isContract": true,
            "network": "base-sepolia",
            "proxy": {
              "detected": true,
              "implementation": "0xd74cc5d436923b8ba2c179b4bCA2841D8A52C5B5",
              "type": "eip1967"
            },
            "token": {
              "decimals": 6,
              "erc20Like": true,
              "name": "USDC",
              "symbol": "USDC",
              "totalSupply": "1000000000000"
            }
          },
          "type": "json"
        }
      },
      "schema": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "properties": {
          "input": {
            "additionalProperties": false,
            "properties": {
              "body": {
                "additionalProperties": false,
                "properties": {
                  "address": {
                    "pattern": "^0x[0-9a-fA-F]{40}$",
                    "type": "string"
                  }
                },
                "required": [
                  "address"
                ],
                "type": "object"
              },
              "bodyType": {
                "enum": [
                  "json",
                  "form-data",
                  "text"
                ],
                "type": "string"
              },
              "method": {
                "enum": [
                  "POST"
                ],
                "type": "string"
              },
              "type": {
                "const": "http",
                "type": "string"
              }
            },
            "required": [
              "type",
              "method",
              "bodyType",
              "body"
            ],
            "type": "object"
          },
          "output": {
            "properties": {
              "example": {
                "additionalProperties": false,
                "properties": {
                  "address": {
                    "pattern": "^0x[0-9a-fA-F]{40}$",
                    "type": "string"
                  },
                  "chain": {
                    "additionalProperties": false,
                    "properties": {
                      "blockNumber": {
                        "minimum": 0,
                        "type": "integer"
                      },
                      "headAgeSeconds": {
                        "minimum": 0,
                        "type": "integer"
                      },
                      "headTimestamp": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "blockNumber",
                      "headTimestamp",
                      "headAgeSeconds"
                    ],
                    "type": "object"
                  },
                  "chainId": {
                    "const": 84532,
                    "type": "number"
                  },
                  "checkedAt": {
                    "type": "string"
                  },
                  "codeHash": {
                    "anyOf": [
                      {
                        "pattern": "^0x[0-9a-fA-F]{64}$",
                        "type": "string"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "codeSizeBytes": {
                    "anyOf": [
                      {
                        "minimum": 0,
                        "type": "integer"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "isContract": {
                    "type": "boolean"
                  },
                  "network": {
                    "const": "base-sepolia",
                    "type": "string"
                  },
                  "proxy": {
                    "additionalProperties": false,
                    "properties": {
                      "detected": {
                        "type": "boolean"
                      },
                      "implementation": {
                        "anyOf": [
                          {
                            "pattern": "^0x[0-9a-fA-F]{40}$",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "type": {
                        "anyOf": [
                          {
                            "const": "eip1967",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "required": [
                      "detected",
                      "type",
                      "implementation"
                    ],
                    "type": "object"
                  },
                  "token": {
                    "anyOf": [
                      {
                        "additionalProperties": false,
                        "properties": {
                          "decimals": {
                            "anyOf": [
                              {
                                "maximum": 255,
                                "minimum": 0,
                                "type": "integer"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "erc20Like": {
                            "type": "boolean"
                          },
                          "name": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "symbol": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "totalSupply": {
                            "anyOf": [
                              {
                                "pattern": "^\\d+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "erc20Like",
                          "name",
                          "symbol",
                          "decimals",
                          "totalSupply"
                        ],
                        "type": "object"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  }
                },
                "required": [
                  "network",
                  "chainId",
                  "address",
                  "isContract",
                  "codeSizeBytes",
                  "codeHash",
                  "proxy",
                  "token",
                  "chain",
                  "checkedAt"
                ],
                "type": "object"
              },
              "type": {
                "type": "string"
              }
            },
            "required": [
              "type"
            ],
            "type": "object"
          }
        },
        "required": [
          "input"
        ],
        "type": "object"
      }
    }
  },
  "tags": [
    "bazaar"
  ],
  "sourceHost": "agent-api-testnet.tim1712.workers.dev",
  "lastUpdated": "2026-08-30T12:14:28.621Z",
  "quality": {
    "calls30d": 1,
    "uniquePayers30d": 1,
    "lastCalledAt": "2026-08-30T12:14:28.297Z"
  },
  "liveness": {},
  "verified": false,
  "featured": false,
  "provider": {
    "host": "agent-api-testnet.tim1712.workers.dev",
    "manifest_name": "agent-api-testnet.tim1712.workers.dev",
    "source": "cdp-mirror",
    "source_manifest_url": "https://api.cdp.coinbase.com/platform/v2/x402/discovery/resources",
    "submitted_at": "2026-09-18T22:00:31.484Z"
  }
}