Skip to main content
You can use LlamaIndex to interact with FriendliAI. This makes migration of existing applications already using LlamaIndex particularly easy.

How to Use

Before you start, ensure you’ve already obtained the API_KEY from the Friendli Suite > Personal Settings > API Keys.

Instantiation

Now you can instantiate the model object and generate chat completions. If you don’t specify a model, the default model (i.e. zai-org/GLM-5.3) is used.

Chat Completion

Generate a response from a given conversation.

Completion

Generate a response from a given prompt.
Last modified on September 9, 2026