# errorType

```graphql
query ErrorType($slug: String!) {
  errorType(slug: $slug) {
    slug
    title
    status
    category
    suggestion
    docs
    solution {
      message
      steps
      example
      tips
      relatedErrors
    }
  }
}
```

Get an API error type.

## Arguments

| Name   | Type    | Required | Description                                                                                     |
| ------ | ------- | -------- | ----------------------------------------------------------------------------------------------- |
| `slug` | String! | Yes      | Error slug identifier (e.g. "insufficient-credits"). Returns solution steps and related errors. |

## Variables

```json
{
  "slug": "string"
}
```

## Responses

| Status | Description                         |
| ------ | ----------------------------------- |
| 200    | The ApiErrorType in data.errorType. |

## Call it

```bash
curl -X POST "https://api.veryfront.com/graphql" \
  -H "Authorization: Bearer $VERYFRONT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "query": "query ErrorType($slug: String!) {\n  errorType(slug: $slug) {\n    slug\n    title\n    status\n    category\n    suggestion\n    docs\n    solution {\n      message\n      steps\n      example\n      tips\n      relatedErrors\n    }\n  }\n}",
  "variables": {
    "slug": "string"
  }
}'
```

## Example response

```json
{
  "data": {
    "errorType": {
      "slug": "string",
      "title": "string",
      "status": 0,
      "category": "string",
      "suggestion": "string",
      "docs": "string",
      "solution": {
        "message": "string",
        "steps": [
          "string"
        ],
        "example": "string",
        "tips": [
          "string"
        ],
        "relatedErrors": [
          "string"
        ]
      }
    }
  }
}
```
