Connects Cohere to Courier, the messaging tool.
You will need to fetch an API token from your Courier org. See the docs. Use this value for the COURIER_API_TOKEN
environment variable.
Create a virtual environment and install dependencies with poetry. We recommend using in-project virtual environments:
poetry config virtualenvs.in-project true
poetry install --no-root
To run the Flask server in development mode, please run:
poetry run flask --app provider --debug run
The Flask API will be bound to :code:localhost:5000
.
curl --request POST \
--url http://localhost:5000/search \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <CONNECTOR_API_KEY>' \
--data '{
"query": "BBQ"
}'
Alternatively, load up the Swagger UI and try out the API from a browser: http://localhost:5000/ui/