Skip to main content

Use Mixtral-8X22B with Portkey

Python
You will need Portkey and Together AI API keys to run this notebook.
  • Sign up for Portkey and generate your API key here
  • Get your Together AI key here

With OpenAI Client

OpenAI Python

With Portkey Client

Note: Add your Together API key in Model Catalog and access models using your provider slug
Python
Output

Observability with Portkey

By routing requests through Portkey you can track a number of metrics like - tokens used, latency, cost, etc. Here’s a screenshot of the dashboard you get with Portkey!
Last modified on April 8, 2026