# Models

## The ValidationErrorItem object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"ValidationErrorItem":{"type":"object","properties":{"loc":{"type":"array","items":{"type":"string"}},"msg":{"type":"string"},"type":{"type":"string"}}}}}}
```

## The ValidationError object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"ValidationError":{"type":"object","properties":{"detail":{"type":"array","items":{"$ref":"#/components/schemas/ValidationErrorItem"}}}},"ValidationErrorItem":{"type":"object","properties":{"loc":{"type":"array","items":{"type":"string"}},"msg":{"type":"string"},"type":{"type":"string"}}}}}}
```

## The ResponseWrapper object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"ResponseWrapper":{"type":"object","properties":{"error":{"type":"integer","description":"Status code (e.g., 256 for OK)"},"message":{"type":"string","description":"Status message"},"parameters":{"type":"object","description":"The main response payload"}}}}}}
```

## The RatingV4 object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"RatingV4":{"type":"object","properties":{"hex":{"type":"string"},"human":{"type":"string"},"letter":{"type":"string"}}}}}}
```

## The LinkValue object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"LinkValue":{"type":"object","properties":{"value":{"type":"string"}}}}}}
```

## The LinkCategory object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"LinkCategory":{"type":"object","properties":{"service":{"$ref":"#/components/schemas/LinkValue"},"documents":{"$ref":"#/components/schemas/LinkValue"},"new_comment":{"$ref":"#/components/schemas/LinkValue"},"edit":{"$ref":"#/components/schemas/LinkValue"},"api":{"$ref":"#/components/schemas/LinkValue"},"badge":{"$ref":"#/components/schemas/LinkValue"}}},"LinkValue":{"type":"object","properties":{"value":{"type":"string"}}}}}}
```

## The ServiceV4 object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"ServiceV4":{"type":"object","properties":{"id":{"type":"string","description":"Unique ID of the service"},"is_comprehensively_reviewed":{"type":"boolean","description":"Indicates if the service has a comprehensive review"},"urls":{"type":"array","items":{"type":"string"}},"name":{"type":"string"},"status":{"type":"string"},"updated_at":{"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"},"slug":{"type":"string"},"wikipedia":{"type":"string","format":"uri"},"rating":{"$ref":"#/components/schemas/RatingV4"},"links":{"type":"object","properties":{"phoenix":{"$ref":"#/components/schemas/LinkCategory"},"crisp":{"$ref":"#/components/schemas/LinkCategory"}}}}},"RatingV4":{"type":"object","properties":{"hex":{"type":"string"},"human":{"type":"string"},"letter":{"type":"string"}}},"LinkCategory":{"type":"object","properties":{"service":{"$ref":"#/components/schemas/LinkValue"},"documents":{"$ref":"#/components/schemas/LinkValue"},"new_comment":{"$ref":"#/components/schemas/LinkValue"},"edit":{"$ref":"#/components/schemas/LinkValue"},"api":{"$ref":"#/components/schemas/LinkValue"},"badge":{"$ref":"#/components/schemas/LinkValue"}}},"LinkValue":{"type":"object","properties":{"value":{"type":"string"}}}}}}
```

## The DocumentReference object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"DocumentReference":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"url":{"type":"string","format":"uri"},"updated_at":{"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"}}}}}}
```

## The CaseV3 object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"CaseV3":{"type":"object","properties":{"id":{"type":"integer"},"weight":{"type":"integer"},"title":{"type":"string"},"localized_title":{"type":"string","nullable":true},"description":{"type":"string"},"updated_at":{"type":"string"},"created_at":{"type":"string"},"topic_id":{"type":"integer"},"classification":{"type":"string"}}}}}}
```

## The PointV3 object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"PointV3":{"type":"object","properties":{"id":{"type":"integer"},"title":{"type":"string"},"source":{"type":"string","format":"uri"},"status":{"type":"string"},"analysis":{"type":"string"},"case":{"$ref":"#/components/schemas/CaseV3"},"document_id":{"type":"integer","nullable":true},"updated_at":{"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"}}},"CaseV3":{"type":"object","properties":{"id":{"type":"integer"},"weight":{"type":"integer"},"title":{"type":"string"},"localized_title":{"type":"string","nullable":true},"description":{"type":"string"},"updated_at":{"type":"string"},"created_at":{"type":"string"},"topic_id":{"type":"integer"},"classification":{"type":"string"}}}}}}
```

## The ServiceV3 object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"ServiceV3":{"type":"object","properties":{"id":{"type":"integer"},"is_comprehensively_reviewed":{"type":"boolean"},"name":{"type":"string"},"updated_at":{"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"},"slug":{"type":"string"},"rating":{"type":"string"},"urls":{"type":"array","items":{"type":"string"}},"image":{"type":"string","format":"uri"},"documents":{"type":"array","items":{"$ref":"#/components/schemas/DocumentReference"}},"points":{"type":"array","items":{"$ref":"#/components/schemas/PointV3"}}}},"DocumentReference":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"url":{"type":"string","format":"uri"},"updated_at":{"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"}}},"PointV3":{"type":"object","properties":{"id":{"type":"integer"},"title":{"type":"string"},"source":{"type":"string","format":"uri"},"status":{"type":"string"},"analysis":{"type":"string"},"case":{"$ref":"#/components/schemas/CaseV3"},"document_id":{"type":"integer","nullable":true},"updated_at":{"type":"string","format":"date-time"},"created_at":{"type":"string","format":"date-time"}}},"CaseV3":{"type":"object","properties":{"id":{"type":"integer"},"weight":{"type":"integer"},"title":{"type":"string"},"localized_title":{"type":"string","nullable":true},"description":{"type":"string"},"updated_at":{"type":"string"},"created_at":{"type":"string"},"topic_id":{"type":"integer"},"classification":{"type":"string"}}}}}}
```

## The DocumentV2 object

```json
{"openapi":"3.0.0","info":{"title":"ToS;DR API","version":"1.0.0"},"components":{"schemas":{"DocumentV2":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"url":{"type":"string","format":"uri"},"text":{"type":"string"},"updated_at":{"type":"string"},"created_at":{"type":"string"},"text_version":{"type":"string","nullable":true},"service_id":{"type":"integer"}}}}}}
```
