# Reviews

## GraphQL partial SDLs

This is a graphql reference page. In the llms.txt variant, those components link to the shared partial SDL key list instead of trying to resolve inline GraphQL reference content.

Fetch all available partial SDL keys first:

```text
GET https://docs.commercetools.com/apis/rest/content/by-id?id=ctp:gql-sphere:returnTypesList
```

Then fetch the one or more relevant partial SDL with a key from that list by calling the same endpoint with a schema ID:

```text
GET https://docs.commercetools.com/apis/rest/content/by-id?id=ctp:gql-sphere:schema:<key>
```

The response body is a JSON object keyed by the requested content ID. For example, the key-list request returns a `ctp:gql-sphere:returnTypesList` field and a schema request returns a `ctp:gql-sphere:schema:<key>` field.

**Queries and mutations for managing Reviews in the platform.**

## Queries

### Query Reviews

[fetch SDL for query reviews](#graphql-partial-sdls).

### Get Review

[fetch SDL for query review](#graphql-partial-sdls).

## Mutations

### Create Review

[fetch SDL for mutation createReview](#graphql-partial-sdls).

### Update Review

[fetch SDL for mutation updateReview](#graphql-partial-sdls).

### Delete Review

[fetch SDL for mutation deleteReview](#graphql-partial-sdls).

## Output types

### Review

[fetch SDL for type Review](#graphql-partial-sdls).

### ReviewQueryResult

[fetch SDL for type ReviewQueryResult](#graphql-partial-sdls).

## Input types

### ReviewDraft

[fetch SDL for type ReviewDraft](#graphql-partial-sdls).

### ReviewUpdateAction

[fetch SDL for type ReviewUpdateAction](#graphql-partial-sdls).

### Update actions

#### Set Author Name

[fetch SDL for type SetReviewAuthorName](#graphql-partial-sdls).

#### Set Custom Field

[fetch SDL for type SetReviewCustomField](#graphql-partial-sdls).

#### Set Custom Type

[fetch SDL for type SetReviewCustomType](#graphql-partial-sdls).

#### Set Customer

[fetch SDL for type SetReviewCustomer](#graphql-partial-sdls).

#### Set Key

[fetch SDL for type SetReviewKey](#graphql-partial-sdls).

#### Set Locale

[fetch SDL for type SetReviewLocale](#graphql-partial-sdls).

#### Set Rating

[fetch SDL for type SetReviewRating](#graphql-partial-sdls).

#### Set Target

[fetch SDL for type SetReviewTarget](#graphql-partial-sdls).

#### Set Text

[fetch SDL for type SetReviewText](#graphql-partial-sdls).

#### Set Title

[fetch SDL for type SetReviewTitle](#graphql-partial-sdls).

#### Transition State

[fetch SDL for type TransitionReviewState](#graphql-partial-sdls).

## Related pages

- [Area overview page with navigation](/api.md)
- [Previous page: REST](/api/projects/reviews.md)
- [Search documentation and API specs](/search.md)