# Best Practices

To ensure predictable, stable, and secure CI/CD integrations with Drizz, teams should follow these recommended practices:

1. **Generate fresh tokens for every CI/CD run**\
   Always request a new Auth0 access token at the start of each pipeline to avoid expired or reused credentials. This ensures secure authentication and prevents failures caused by token timeouts.
2. **Upload the APK only when a new build is produced**\
   Avoid unnecessary binary uploads. Push a new APK to Drizz only when the application version changes, reducing storage overhead and preventing accidental conflicts with previously uploaded builds.
3. **Use batch execution for large test suites**\
   When running multiple flows, trigger them as a batch. Batch mode provides better parallelism, improved scalability, and more predictable execution time across devices.
4. **Log complete API request and response details**\
   Store raw API responses (success, error, retry info) in CI logs. Detailed logging accelerates root-cause analysis, makes flaky behaviors easier to track, and simplifies debugging during pipeline failures.
5. **Fail the pipeline on critical test failures**\
   Ensure pipelines enforce quality gates by failing builds when essential test plans fail. This prevents unstable builds from reaching production and maintains high release confidence.

> Support\
> For API access and issues, contact: <support@drizz.dev>


---

# 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.drizz.dev/drizz-api-integration/best-practices.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.
