# REST APIs

### Base Endpoints

#### Testnet

```
https://testnet-rpc.sign.global/api
```

#### Mainnet

```
https://mainnet-rpc.sign.global/api
```

### Hello World

```typescript
GET / index;
```

Status endpoint to verify the attestation backend is functional.

Parameters:

None

Response:

```json
{
  "success": true,
  "statusCode": 200,
  "data": "Welcome to Sign Protocol Service!",
  "message": "ok"
}
```

### Super Search

```typescript
GET / scan / search;
```

Search for relevant schemas, attestations, and addresses by providing a keyword and filter.

Query Parameters:

| Key       | Value       | Type                                     |
| --------- | ----------- | ---------------------------------------- |
| filter\*  | attestation | `"schema"`, `"attestation"`, `"address"` |
| keyword\* | 0x1         | string                                   |

\* Optional parameter.

Response:

```json
{
    "success": true,
    "statusCode": 200,
    "data": {
        "queryResult": [
            {
                "type": "attestation",
                "rows": [
                    {
                        "id": "onchain_evm_80001_0x1",
                        "chainType": "evm",
                        "chainId": "80001",
                        "attestationId": "0x1",
                        "attester": "0x9854E76134e6D729A633CED51042fF653f04f4C5",
                        "recipients": []
                    },
                    ...
                ],
                "total": 2
            }
        ]
    },
    "message": "ok"
}
```

### Get Address Statistics

```typescript
GET / scan / addresses / { address } / statistics;
```

Get attestation and schema statistics for an address.

Query Parameters:

| Key     | Value                                      | Type   |
| ------- | ------------------------------------------ | ------ |
| address | 0x059e6B8008d34aC26581fD3ED8378AA93c7941EE | string |

\* Optional parameter.

Response:

```json
{
  "success": true,
  "statusCode": 200,
  "data": {
    "schemaCreated": 6,
    "totalAttestations": 14,
    "attestationCreated": 13,
    "attestationReceived": 3
  },
  "message": "ok"
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sign.global/for-builders/index/index-1.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
