# Request Cryptogram

## Request Cryptogram - Testing <a href="#request-cryptogram---testing" id="request-cryptogram---testing"></a>

The **CryptoFetch API** retrieves the cryptogram associated with the **active** Network Tokens for a card. This cryptogram is used to facilitate secure, tokenized transactions.

To successfully test CryptoFetch, the card must have an active Network Tokens provisioned with the network in the sandbox environment.

Refer to [VGS Sandbox Network Token](/cmp/developer-resources/guides/testing/create-card.md#method-3a--network-token-provisioning-for-visamastercard-cards-with-networks) Provisioning for guidance on provisioning Network Tokens.

### Points to Note <a href="#points-to-note" id="points-to-note"></a>

* **For CMP accounts with `ON-CREATE` enrollment type:**
  * Network Tokens are automatically provisioned when the card is created.
  * Perform a `GET` on the card ID to verify that the Network Tokens status is `active`.
  * Once verified, you can proceed with the CryptoFetch API call.
* **For CMP accounts with `MANUAL` enrollment type:**
  * Network Tokens are **not** provisioned by default.
  * Use the Network Tokens [Provisioning endpoint](/cmp/developer-resources/api/network-tokens.md#post-cards-card_id-network-tokens) to provision the Network Tokens manually.
  * Then, perform a `GET` to ensure the Network Tokens status is active before calling CryptoFetch.
* **Do not use mock test cards for CryptoFetch testing:**
  * Mock cards do **not** provision Network Tokens with networks.
  * Since CryptoFetch depends on active Network Tokens, it will **not work** with mock cards.

### Testing Steps <a href="#testing-steps" id="testing-steps"></a>

* **Create Cards:** Use the **Create Card API** to register [test cards](/cmp/developer-resources/guides/testing/create-card.md#method-3a--network-token-provisioning-for-visamastercard-cards-with-networks) that support Network Tokens provisioning in the sandbox.
* **Provision Network Tokens (if required):**
  * Skip this step for`ON-CREATE` enrollment (Network Tokens is auto-provisioned).
  * For MANUAL enrollment, call the Network Tokens [Provisioning endpoint](/cmp/developer-resources/api/network-tokens.md#post-cards-card_id-network-tokens).
* **Verify Network Tokens Status**: Use the `GET` **Card API** to check that the Network Tokens status is active.
* **Call Request cryptogram API:** Once the Network Tokens is active, use the [Request cryptogram endpoint](/cmp/developer-resources/api/network-tokens.md#post-cards-card_id-cryptogram) to retrieve the cryptogram for that token.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.verygoodsecurity.com/cmp/developer-resources/guides/testing/request-cryptogram.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
