Put topics about this connector package here.
Always check the ‘How to use the Alumio connector packages’ topic.
Extra information
System documentation: [Perplexity API Reference]
Perplexity
Connector Package Documentation
Setting up HTTP Client Perplexity
Steps
- In Alumio Dashboard, go to Clients > HTTPS Client. Create a new HTTP Client and select Perplexity HTTP Client as the prototype of the HTTP Client.
- Fill in the Base URI, and Api Key.
- Save the Client for use later.
Subscribing to Entities from Perplexity
Steps
- Go to Connections → Incoming and create a new incoming configuration and select Perplexity Subscriber as the subscriber.
- Select the entity you want to subscribe from Perplexity .
- Add any request parameters needed to subscribe to the entity (optional).
- You can optionally add a transformer to transform the request parameters into something you need.
- Select the Perplexity HTTP Client to use.
General Concept
We follow Perplexity documentation on building this connector so you can easily use the connector based on Perplexity API Reference.
Method
It’s the Method you want to subscribe from Perplexity. Based on the Method, the Entity will change. Please refer to the entities in Management APIs from Perplexity API Reference page.
Entity
It’s the entity you want to subscribe from Perplexity . Perplexity only has one Endpoint to support. Please refer to the entities in Management APIs from Perplexity API Reference page.
Request Parameters
These are the parameters you can provide to get the needed entity based on Perplexity API Reference. Please look at the example below on how to fill the Request Parameters field when subscribing Stream – Chat Completions.
Here is the final URL that will be called when using such Request Parameters field on Retrieve a single field.
/chat/completions
Input Transformer
Any transformer’s set here will be executed after the Request Parameters are loaded. So, you basically can add any transformer to provide and transform the request parameters into anything you need either as path parameters and/or as query parameters of an entity.
HTTP Client
It’s the HTTP Client configuration or prototype you will use to access Perplexity .
Publishing Entity to Perplexity
Steps
- Go to Connections → Outgoing, create a new outgoing configuration, and select Perplexity Publisher as the publisher.
- Select the Method that you want the publisher to do with the data.
- Select the Perplexity entity you want the data to be published.
- You can optionally add any query parameters to the request.
- You can also optionally add any transformers to transform the data into anything you need before submitting it to Perplexity .
- Select the HTTP Client to use.
General Concept
Like the subscriber, the publisher has similar methods on how to use it. Normally the difference is the payload that will be submitted by the publisher originating from the data (from routes, from transformers in outgoing configuration) but for perplexity we only support one endpoint to use on subscriber and publisher (same endpoint), though you can also add or modify payload using the Request Transformer.
Method
Currently, we only support Post (HTTP POST method).
Entity
We support publishing to most Perplexity endpoints. Please refer to the entities in Management APIs from the Perplexity API Reference page. Based on the documentation, some endpoints may need one or more path parameters.
For endpoints that require an object as the request payload, please look at the example below. For example, we want to Generate a model response for the given chat conversation. Please select “Post” as the action and “Chat Completions” as the entity of the publisher.
You can put the payload you want to send to Perplexity into the payload property in the data.
Alumio will send an API request to Perplexity with URL /chat/completions
HTTP Client
It’s the HTTP Client configuration or prototype you will use to access Perplexity .