# Web2 Account

## <mark style="color:blue;">GET</mark> /api/v1/web2/account

* Note: It is for querying a user's associated Web2 accounts. (Twitter is supported now)
* Header

| Field         | Type   | Remarks                                                                                             |
| ------------- | ------ | --------------------------------------------------------------------------------------------------- |
| ApiKey        | String | The ApiKey obtained from Admin.                                                                     |
| Authorization | String | Bearer ${unifiedAuthToken} , in which the "unifiedAuthToken" is the result returned by /api/v1/auth |

* Request Parameters

| Field   | Type   | Remarks      |
| ------- | ------ | ------------ |
| address | String | web3 address |

* Request Example

```shell
curl   GET 'https://api.relationlabs.ai/api/v1/web2/account?address=0x5fda2abc07ce479e1edeb510d83ef499a532be31' \
--header 'ApiKey: 〈ApiKey>' \
--header 'Authorization: bearer eyJhbGciOiJ1FUzI1NiJ9.eyJqdGkiOiI5MmFlMjc5OWE5MDk0YzY0ODllZTYzOD1kyYmRkZmUxZSIsImlzcyI6InJlbGF0aW9ubGFicy5haSIsImlhdCI6MTY2MjA5MTYxMywic3ViIjoiYmFmMzQta2lhYWEtYWFhYWstYWNnamEtY2FpIiwiZXhwIjoxNjYyNjk2NDEzfQ.fQP4SO6dmptRUvWEp6GGRNTJrXhRL2g2Z07UzYLQF01nd74uNd3KYnlqv5-leOs0M1Fm5dy-EUhPZQ_272nnb5Q'
```

* Response Parameters

| Field | Type               | Remarks            |
| ----- | ------------------ | ------------------ |
| code  | String             | Return Code        |
| desc  | String             | Return Informatiom |
| data  | List\[Web2Account] | Data               |

The Web2Account field consists of the following subfields:

| Field    | Type   | Remarks                   |
| -------- | ------ | ------------------------- |
| account  | String | User's Web2 account       |
| platform | String | Web2 platforms: 0-twitter |

* Response Body

```json
{
    "code": "0",
    "desc": "success",
    "data": [
        {
            "account": "rambo76909093",
            "platform": 0
        }
    ]
}
```

* Return Code

| code | desc    | Remarks                             |
| ---- | ------- | ----------------------------------- |
| 0    | success | The flag for a successful API call. |


---

# 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://relationlabs.gitbook.io/relation-one-api/api/profile/web2-account.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.
