This document provides detailed information about the REST API's available for the Alli LLM App Market. We currently provide APIs to get and run LLM Apps, and more APIs will be added in the future.
Kindly be advised that the utilization of the Alli App Market is not universally accessible to all clients. Should you express interest in utilizing our App Market, we recommend that you reach out to your designated account manager for further information and guidance.
Getting the API KEY
Please provide your API key in the request header API-KEY. Your API key can be found in your dashboard Settings menu, under the General tab.
Error Messages
Please read the error message you get if you don't get the response that you expected. For example, if you don't use the right HTTP method for the API, you'll get this type of error as response:
{“error”: “Method Not Allowed POST: /webapi/apps”}
If you don't include the inputs when running the LLM App for example, you'll get this type of error as a response:
Run LLM App API allows you to run the desired skill/conversational or single-action app.
Headers
Request Body
Single Action Request Example
Please replace YOUR_REST_API_KEY with your one in the example below. Please see getting-api-key section.
curl -vv -X POST \
'https://backend.alli.ai/webapi/apps/TExNQXBwOjY1NWVlYTMzY2IzMzQ1OTVkZjQwNzdhZg==/run' \
--header 'Accept: */*' \
--header 'API-KEY: YOUR_REST_API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{"inputs":{"input": "The Little Prince has sold approximately 140 million copies worldwide, making it one of the best-selling and most translated books ever published. To date, it has been translated into 301 languages and dialects. It was the first novel to be published in the United States. The story of the novel is interesting: Saint-Exupéry was in New York City, and while having dinner with his American publisher, Eugene Reynal, he doodled a child on a napkin. When Eugene Reynal saw the drawing, he suggested to Saint-Maximilien that it would be a good idea to write a children's book about the child before Christmas. (It is said that Eugène Reynal suggested it to relieve his stress.) The basic sketch of the Little Prince was based on a statue of the baby Jesus in Prague, Czech Republic. The narrator, a pilot, was also inspired by visions Saint-Exupéry himself experienced when he and his co-pilot crash-landed in the Sahara Desert in 1935 and were stranded for five days without a drop of water."}}'
Single Action Response Example
{
"result": {
"id": "TExNQXBwOjY1NWVlYTMzY2IzMzQ1OTVkZjQwNzdhZg==",
"name": "Summary Single-action App",
"type": "single_action",
"category": "General",
"choices": [
{
"id": "U2luZ2xlQWN0aW9uOjY1NWVlZjQ4M2JhMTIzYzA3YWZmNWUzOQ==",
"type": "llm",
"message": "The Little Prince is one of the world's best-selling books, with over 140 million copies sold, and has been translated into 301 languages. The novel was first published in the United States and was the brainchild of publisher Eugene Reynal. The basic sketch of The Little Prince was inspired by the Baby Jesus statue in Prague, Czech Republic, and the pilot was inspired by Saint-Exupéry's own experiences in the Sahara Desert."
}
]
}
}
Conversational/Skill Request Example
Currently, Skills that require user interaction in the middle of the app execution (e.g., asking the user to make a selection, enter a message, etc.) are not supported by the LLM App API. (However, launching an LLM node after uploading a document is an exception, as shown in the example below).
Please replace YOUR_REST_API_KEY with your one in the example below. Please see getting-api-key section.