# Key encoding

This section relates on how raw key data is encoded. The encoding of DiME key items is outlined in the previous chapter [General encoding](https://docs.dimeformat.io/encoding/general-encoding). As with the overall DiME item, Base64 is also used to encode raw key material.&#x20;

{% code overflow="wrap" %}

```json
"key": "DSC.7VN2b6f0nxqubSU955PuMenLtV6u9ltQr0ovUG0CL0Rfhb9S9IvUapNj58CHcsVwMYr3bOw/aghjECVcua2M+Q"
"pub": "DSC.X4W/UvSL1GqTY+fAh3LFcDGK92zsP2oIYxAlXLmtjPk"
```

{% endcode %}

The ‘key’ claim contains the secret key whereas the ‘pub’ claim contains the public key. The cryptographic suite used to generate the key is indicated by the initial header (‘DSC’). For more information about suites, see the chapter [Suites](/cryptography/profiles.md), which details out the use of cryptographic suites.


---

# 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.dimeformat.io/encoding/key-encoding.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.
