# Constants & Secrets

### Creating Constants

<figure><img src="/files/FoExvTpqGzgjOuzS7DVY" alt=""><figcaption><p>Constants</p></figcaption></figure>

Constants within our app are asset functions that are leveraged to use values that do not change during the execution of a program. They are typically used to represent fixed, unchanging data in code, making it easier to manage and understand.

### Importing constants into Canvas

<figure><img src="/files/oicDsjF7k68ZPHYWxmm7" alt=""><figcaption><p>Adding Constants</p></figcaption></figure>

You can attach any asset to a canvas by following the procedure above.

<figure><img src="/files/r8GZq6ljr5Kt7g7arzIF" alt=""><figcaption></figcaption></figure>

In canvas, the constants are often used as imports within libraries to make commonly used values available to users of the library in a convenient and consistent way.

### Creating Secret Constants

<figure><img src="/files/bzF3GqmpN7b3uhpQGjKm" alt=""><figcaption><p>Secret Constants</p></figcaption></figure>

Secret constants are essential for accessing sensitive data such as API keys, passwords, access tokens and other confidential data that a program or application needs for execution. This can be easily achieved by using "make secret" or "Secret" option while or after creating the constant.

<figure><img src="/files/5N3OuyvWUUjN79nn7Iah" alt=""><figcaption><p>Hiding Secret Key</p></figcaption></figure>

Secrets within asset function can utilize anonymization of the confidential data in canvas for seamless coding experience among team members in an organization.


---

# 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.zerve.ai/guide/notebook-view/assets/constants-and-secrets.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.
