Magidoc

Working with a GraphQL API

Welcome to Rasayel's public API, which is built with GraphQL. Just like the public API, the Rasayel Inbox app also uses a similar API with inbox-specific features.

If you're new to GraphQL, we recommend checking out the official GraphQL learning docs as a starting point. Apollo also offers great resources and tools to help you work with GraphQL APIs.

We also have a getting started guide in the next page, Working with GraphQL

Endpoint

#

    
  

Authentication

#

To authenticate your client, you'll need to create API keys from Rasayel's API management page. These API keys provide a value for the Authorization header, which you should configure with your chosen GraphQL client or HTTP request.

    
  

Some keys can be created as "read-only" (supporting queries), while others can be created as "read-write" (supporting both queries and mutations). Make sure you use the correct key access before using the API.

Getting Started

#

Once you have your API key and a GraphQL client that can introspect the schema, you're ready to start using the available queries and mutations.

Here are a few popular clients you can use:

Queries

#

To get started, you can start by listing the last 10 conversations in your workspace:

    
  

Mutations

#

Now that you've successfully fetched a few conversations, let's try replying to one of them. Just make sure to change the conversationId value to match one of the conversations returned earlier.