# Quick Start

{% hint style="info" %}
The [](https://docs.okendo.io/merchant-rest-api "mention") API is **not** intended for client-side use.

For public and client-side use, see the [storefront-rest-api](https://docs.okendo.io/on-site/storefront-rest-api "mention").
{% endhint %}

## Get Your Credentials

Your API requests are authenticated using your Okendo User ID and an API Key. You can get these details from the integration settings section of the Okendo app.

## Make Your First Request

To make your first request, send an authenticated request to the `/reviews` endpoint. This will fetch some of your published `reviews`.

## List Reviews

> Returns a list of Reviews for the requested store

```json
{"openapi":"3.0.1","info":{"title":"Okendo Enterprise API","version":"1.2.1"},"tags":[{"name":"reviews"}],"servers":[{"url":"https://api.okendo.io/enterprise"}],"security":[{"basic":[]}],"components":{"securitySchemes":{"basic":{"type":"http","scheme":"basic"}}},"paths":{"/reviews":{"get":{"tags":["reviews"],"summary":"List Reviews","description":"Returns a list of Reviews for the requested store","parameters":[{"description":"A limit on the number of items returned. Between 1 and 100. Default 25.","in":"query","name":"limit","required":false,"schema":{"type":"integer","format":"int32"}},{"name":"lastEvaluated","description":"The URL-encoded JSON object representing the cursor for the next page of results.","in":"query","required":false,"schema":{"type":"string"}},{"name":"orderBy","description":"The sort order of the reviews. Format: '(date|rating) (asc|desc)'. Default 'date desc'","in":"query","required":false,"schema":{"type":"string"}},{"name":"status","description":"A filter on the Reviews based on the review's moderation status. The value must be one of 'approved', 'pending', 'rejected'. Default 'approved'.","in":"query","required":false,"schema":{"type":"string","enum":["approved","pending","rejected"],"description":"The moderation status of the review."}}],"responses":{"200":{"description":"An object containing a list of Reviews and a relative link to the next page of results if available.","content":{"application/json":{"schema":{"type":"object","properties":{"reviews":{"type":"array","items":{"type":"object","properties":{"subscriberId":{"type":"string","description":"Your user id within Okendo.","format":"uuid"},"reviewId":{"type":"string","format":"uuid"},"productId":{"type":"string","description":"The product ID prefixed by a platform identifier."},"attributesWithRating":{"type":"array","items":{"type":"object","properties":{"minLabel":{"type":"string","description":"The label for the leading edge of an attribute bar."},"midLabel":{"type":"string","description":"The label for the midpoint of a centered-range attribute bar."},"maxLabel":{"type":"string","description":"The label for the trailing edge of an attribute bar."},"title":{"type":"string","description":"The title of the attribute."},"type":{"type":"string","enum":["centered-range","range"]},"value":{"type":"number","description":"The value selected on the attribute scale. For attribute of type 'range' this is between 1 and 5. For 'centered-range', between -1 and 1."}},"required":["title","type","value"]}},"body":{"type":"string","description":"The content of the review."},"containsProfanity":{"type":"boolean","description":"true if the title or body contain words on the profanity list, otherwise false."},"dateCreated":{"type":"string","format":"date-time"},"helpfulCount":{"type":"integer","format":"int32","description":"The number of upvotes a review has received."},"isIncentivized":{"type":"boolean"},"isRecommended":{"type":"boolean"},"media":{"type":"array","items":{"type":"object","properties":{"streamId":{"type":"string","format":"uuid"},"fullSizeUrl":{"type":"string","format":"uri"},"largeUrl":{"type":"string","format":"uri"},"thumbnailUrl":{"type":"string","format":"uri"},"type":{"type":"string","enum":["image","video"]},"isHidden":{"type":"boolean"}},"required":["fullSizeUrl","thumbnailUrl","type","streamId","isHidden"]},"minItems":1},"productAttributes":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","description":"The title of the attribute."},"type":{"type":"string","enum":["drop-down","multi-value","single-value"]},"value":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"The selected value(s) for the attribute. For types 'drop-down' and 'single-select' this is a single value. For type 'multi-select' it is an array."}},"required":["title","type","value"]}},"productName":{"type":"string"},"order":{"type":"object","properties":{"orderId":{"type":"string"},"orderNumber":{"type":"string"}}},"rating":{"type":"integer","format":"int32","minimum":1,"maximum":5,"description":"The number of stars a review has received."},"reply":{"type":"object","properties":{"body":{"type":"string","format":"html","description":"The html representation of the review reply."},"dateCreated":{"type":"string","format":"date-time"},"rawBody":{"type":"string","description":"The reply entered by the user. (Note: can include markdown syntax)."},"isPrivate":{"type":"boolean","description":"true if the reply is unpublished otherwise false."}},"required":["body"]},"reviewer":{"type":"object","properties":{"attributes":{"type":"array","items":{"type":"object","properties":{"title":{"type":"string","description":"The title of the attribute."},"type":{"type":"string","enum":["drop-down","multi-value","single-value"]},"value":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"The selected value(s) for the attribute. For types 'drop-down' and 'single-select' this is a single value. For type 'multi-select' it is an array."}},"required":["title","type","value"]}},"avatarUrl":{"type":"string","format":"uri"},"displayName":{"type":"string","description":"The full name entered by the reviewer with the last name truncated."},"email":{"type":"string","format":"email"},"isVerified":{"type":"boolean"},"location":{"type":"object","properties":{"country":{"type":"object","properties":{"code":{"type":"string"},"name":{"type":"string"}}},"zoneCode":{"type":"string"}}},"name":{"type":"string","description":"The full name entered by the reviewer."},"socialConnection":{"type":"string","enum":["facebook","google"]},"verifiedStatus":{"type":"string","enum":["Verified Buyer","Verified Reviewer"],"description":"'Verified Buyer' if the reviewer could be connected to a valid order. 'Verified Reviewer' if the reviewer could not be connected to a valid order but verified their email address."}},"required":["displayName","name"]},"reward":{"type":"object","properties":{"description":{"type":"string"},"integration":{"type":"string"},"type":{"type":"string","enum":["coupon","points","event"]},"value":{"type":"string"},"isCouponUpgrade":{"type":"boolean"}},"required":["type","value"]},"sentiment":{"type":"string","enum":["positive","negative","neutral","mixed"],"description":"The natural language sentiment of the review title and body."},"status":{"type":"string","enum":["approved","pending","rejected"],"description":"The moderation status of the review."},"tags":{"type":"array","items":{"type":"string"},"description":"The names of any tags added to the review."},"title":{"type":"string","description":"The title of the review."},"unhelpfulCount":{"type":"integer","format":"int32","description":"The number of downvotes a review has received."},"variantId":{"type":"string","description":"The id of the reviewed Shopify product variant."},"variantName":{"type":"string","description":"The name of the reviewed Shopify product variant."}},"required":["subscriberId","reviewId","productId","body","dateCreated","rating","reviewer","status","title","unhelpfulCount"]}},"nextUrl":{"type":"string","format":"uri"}}}}}},"400":{"description":"Invalid request parameters.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"description":{"type":"string"}}}}}}}},"401":{"description":"Authentication credentials are missing or incorrect."}}}}}}
```

To make the request, use a networking client of your choice or follow these examples:

{% tabs %}
{% tab title="Node.js Fetch" %}

```javascript
const response = await fetch('https://api.okendo.io/enterprise/reviews', {
  headers: {
    'Authorization': 'Basic ' + Buffer.from('<okendo_user_id>:<api_key>').toString('base64'),
    'okendo-api-version': '2025-02-01'
  }
});

const data = await response.json();
```

{% endtab %}

{% tab title="cURL" %}

```bash
curl -X GET "https://api.okendo.io/enterprise/reviews" \
  -u "<okendo_user_id>:<api_key>" \
  -H "okendo-api-version: 2025-02-01"
```

{% endtab %}
{% endtabs %}
