---
title: "Search for Credentials (v2)"
method: POST
path: "/v2/credentials/search"
tags: ["Credentials"]
---

# Search for Credentials (v2)

`POST /v2/credentials/search`

This is a faster alternative to the v1 Search API. It also supports operations on the query fields which can allow you to form more complex queries.

Following operations are **supported based on the field**. You can also combine operations on multiple fields:

| Operation | Description | Example |
|-----------|-------------|----------|
| `eq` | Exact match (default, if nothing specified). | `{"group.id[eq]": 1}` or `{"group.id": 1}` - Both yield the same result. |
| `in` | Allows an array of values. | `{"group.id[in]": [1, 2]}` |
| `lt` | Less than. | `{"issued_on[lt]": "2023-12-31"}` |
| `gt` | Greater than. | `{"issued_on[gt]": "2023-01-01"}` |
| `lte` | Less than equal to. | `{"expired_on[lte]": "2023-12-31"}` |
| `gte` | Greater than equal to. | `{"expired_on[gte]": "2023-01-01"}` |

**Note:** Offset-based pagination using `page.from` + `page.size` supports a maximum of 10,000 results. To retrieve results beyond this limit, use cursor-based pagination with `page.cursor` and `page.size`.

**Note:** Results from this endpoint do **not** carry the `skills` field that the other credential endpoints return. To read a credential's framework skills, fetch it with [View a Credential](#operation/View%20a%20Credential).

## Request body

- object
  - `query` object, required
    - `uuid` string — Limit the returned credentials to a specific UUID. Supported operations - `eq`, `in`
    - `group.id` string — Limit the returned credentials to a specific group ID. Supported operations - `eq`, `in`
    - `recipient_name` string — Limit the returned credentials to a recipient's name. Supported operations - `eq`, `in`
    - `approve` boolean — Return only published or unpublished credentials by specifying the desired value (true/false). If not specified, all credentials will be returned. Supported operations - `eq`
    - `recipient_email` string — Limit the returned credentials to a specific recipient's email address. Supported operations - `eq`, `in`
    - `recipient_id` string — Limit the returned credentials to a specific recipient user identifier (ID) you set whilst creating credentials. Supported operations - `eq`, `in`
    - `recipient_meta_data` object — String key/values for client's own data on the recipient. Supported operations - none
    - `license_id` string — Limit the returned credentials to a specific credential id you set whilst creating the credential. Supported operations - `eq`, `in`
    - `meta_data` object — String key/values for client's own data on the credential. Supported operations - none
    - `custom_attributes` object — String key/values for client's own data on the credential. Supported operations - none
    - `issued_on` string — Date on which the credentials have been issued. Format: YYYY-MM-DD Supported operations - `eq`, `in`, `lt`, `lte`, `gt`, `gte`
    - `expired_on` string — Date on which the credentials will expire. Format: YYYY-MM-DD Supported operations - `eq`, `in`, `lt`, `lte`, `gt`, `gte`
    - `updated_at` string — Date on which the credentials have been updated. Format: YYYY-MM-DD Supported operations - `eq`, `in`, `lt`, `lte`, `gt`, `gte`
    - `created_at` string — Date on which the credentials have been created. Format: YYYY-MM-DD Supported operations - `eq`, `in`, `lt`, `lte`, `gt`, `gte`
  - `sort` object
    - `String key/value pair for sorting based on a field and order.` string — Supported keys - `id`, `recipient_name`, `group.name`, `issued_on` and `expired_on`. Supported values - `asc`, `desc`
  - `page` object
    - `from` integer — Number of records to skip (offset-based pagination). Limited to the first 10,000 results. Cannot be used together with `cursor`.
    - `size` integer — The number of records to be returned. Default is 50
    - `cursor` string — An opaque pagination token returned by a previous response. Use this to retrieve the next page of results. Cannot be used together with `from`.

## Response `200`

OK

- object
  - `credentials` object[]
    - `encoded_id` string
    - `private` boolean
    - `recipient_opened` boolean
    - `seo_image` string
    - `published_on` string, nullable
    - `recipient_email` string
    - `created_at` string
    - `recipient_engaged` boolean
    - `uuid` string
    - `custom_attributes` object, nullable
    - `issuer_id` number
    - `recipient_meta_data` object, nullable
    - `updated_at` string
    - `approve` boolean
    - `license_id` string, nullable
    - `grade` unknown
    - `meta_data` object, nullable
    - `name` string
    - `issued_on` string
    - `id` number
    - `recipient_name` string
    - `group` object
      - `course_name` string
      - `badge_design_id` number, nullable
      - `certificate_design_id` number, nullable
      - `name` string
      - `phone_number` string, nullable
      - `id` number
    - `expired_on` string, nullable
    - `recipient_id` string, nullable
  - `meta` object
    - `count` number
    - `from` number
    - `size` number
    - `cursor` string

---

[API](https://skmtc.net/accredible/apis/accredible-credential-api.md) · [All operations](https://skmtc.net/accredible/apis/accredible-credential-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/accredible/accredible-credential-api/versions/56b317c13686/schema)
