> For the complete documentation index, see [llms.txt](https://cifer.gitbook.io/cifer-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cifer.gitbook.io/cifer-docs/documentation/cifer-sdk/sdk-reference/integration-patterns.md).

# Integration patterns

## Browser Web3 application

Use `createCiferSdk()`, an EIP-1193 signer adapter, the user's wallet for transaction intents, and payload/file helpers for encrypted data.

## Consumer Web2 application

Use `web2.createClient()`, platform secure storage for the Ed25519 identity key, managed sessions, and principal-based secret operations.

## Server-side service

Use explicit read and signer adapters backed by a key-management system. Separate tenants, environments, retry queues, and audit logs. Never hardcode production private keys.

## Shared encrypted records

Encrypt to a secret, appoint a delegate or issue an appropriate permit, and record the application-level reason and lifecycle of the grant. Remember that revocation cannot erase previously decrypted copies.

## Verifiable encrypted record

Encrypt the payload, build a commitment storage intent, submit it through the application's transaction layer, parse the resulting metadata/logs, verify hashes during retrieval, and request authorized decryption.

## Large file workflow

Upload asynchronously, persist the job ID, poll with bounded backoff, download on completion, and securely remove temporary plaintext.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://cifer.gitbook.io/cifer-docs/documentation/cifer-sdk/sdk-reference/integration-patterns.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
