# Get agent and API-wallet state

> For the complete documentation index, see [llms.txt](/docs/llms.txt).

POST https://api.g.alchemy.com/hypercore/v1/{apiKey}/extra-agents

Retrieve agent and API-wallet information associated with a user.


Reference: https://www.alchemy.com/docs/data/hypercore/rest-api/hyper-core-data-api-endpoints/get-extra-agents

## Path Parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| apiKey | string | Yes |  |

## Code Examples

### cURL

```bash
curl --request POST \
  --url https://api.g.alchemy.com/hypercore/v1/string/extra-agents \
  --header 'Content-Type: application/json' \
  --data '{
  "user": "string",
  "startTime": 1,
  "endTime": 1,
  "cursor": "string",
  "include": [
    "string"
  ]
}'
```

### JavaScript

```javascript
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: JSON.stringify({
    user: 'string',
    startTime: 1,
    endTime: 1,
    cursor: 'string',
    include: ['string']
  })
};

fetch('https://api.g.alchemy.com/hypercore/v1/string/extra-agents', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.g.alchemy.com/hypercore/v1/string/extra-agents"

payload = {
    "user": "string",
    "startTime": 1,
    "endTime": 1,
    "cursor": "string",
    "include": ["string"]
}
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
```

### Go

```go
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.g.alchemy.com/hypercore/v1/string/extra-agents"

	payload := strings.NewReader("{\n  \"user\": \"string\",\n  \"startTime\": 1,\n  \"endTime\": 1,\n  \"cursor\": \"string\",\n  \"include\": [\n    \"string\"\n  ]\n}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
```

### Java

```java
HttpResponse<String> response = Unirest.post("https://api.g.alchemy.com/hypercore/v1/string/extra-agents")
  .header("Content-Type", "application/json")
  .body("{\n  \"user\": \"string\",\n  \"startTime\": 1,\n  \"endTime\": 1,\n  \"cursor\": \"string\",\n  \"include\": [\n    \"string\"\n  ]\n}")
  .asString();
```

### C#

```csharp
using RestSharp;


var options = new RestClientOptions("https://api.g.alchemy.com/hypercore/v1/string/extra-agents");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddJsonBody("{\n  \"user\": \"string\",\n  \"startTime\": 1,\n  \"endTime\": 1,\n  \"cursor\": \"string\",\n  \"include\": [\n    \"string\"\n  ]\n}", false);
var response = await client.PostAsync(request);

Console.WriteLine("{0}", response.Content);

```


## Operation Specification

```yaml
path: /{apiKey}/extra-agents
method: POST
operation:
  operationId: get-extra-agents
  summary: Get agent and API-wallet state
  description: |
    Retrieve agent and API-wallet information associated with a user.
  parameters:
    - name: apiKey
      in: path
      required: true
      schema:
        type: string
  requestBody:
    required: true
    content:
      application/json:
        schema:
          type: object
          required:
            - user
          properties:
            user:
              type: string
              pattern: ^0x[a-fA-F0-9]{40}$
              description: EVM-style account address.
            startTime:
              type: integer
              format: int64
              description: Unix timestamp in milliseconds.
            endTime:
              type: integer
              format: int64
              description: Unix timestamp in milliseconds.
            cursor:
              type: string
              description: Opaque cursor. Store and return it unmodified; its format may change.
            include:
              type: array
              items:
                type: string
  responses:
    '200':
      description: Successful response.
      content:
        application/json:
          schema:
            type: object
            properties:
              user:
                type: string
                pattern: ^0x[a-fA-F0-9]{40}$
                description: EVM-style account address.
              agents:
                type: array
                items:
                  type: object
                  properties:
                    address:
                      type: string
                      pattern: ^0x[a-fA-F0-9]{40}$
                      description: EVM-style account address.
                    name:
                      type: string
                    permissions:
                      type: array
                      items:
                        type: string
          examples:
            default:
              value:
                user: '0x1111111111111111111111111111111111111111'
                agents:
                  - address: '0x4444444444444444444444444444444444444444'
                    name: market-maker
                    permissions:
                      - trade
```
