Absinthe’s off-chain points API allows any project the freedom to issue, query, update, and delete points for any off-chain action.

You can test-drive the API in our interactive graphql playground here.

You will need an API key to set in an authorization header. If you don’t have one yet, reach out to the Absinthe team here to get you one.

Setting The Authorization Header

Before being able to introspect the schema through our interactive graphql playground or through a direct call, you will need to set the API key as an authorization header via this format:

{"Authorization": "Bearer <INSERT_KEY_HERE>"}

Endpoint URL

https://gql3.absinthe.network/v1/graphql

FAQ

The event_name should remain consistent for each distinct event that earns points. It should not be a randomly generated string each time. Consistency in event naming allows easy event querying in the future and enables more meaningful analytics.

Parameters

account_id
string
required

The account id (of type identity_type) that will be the beneficiary of these points (case-insensitive).

event_name
string
required

A descriptive string that describes what the points issuance is for.

amount
number
required

A number greater than or equal to 0 representing the points the address will receive.

identity_type
Enum
required

You can select the type of identity of the account_id, such as EVM_ADDRESS or X_HANDLE.

metadata
json

A JSON formatted string that can can store arbitrary metadata alongside each points issuance event.

applies_to_referral_score
boolean
default: "true"

When this field is set to false, the points that the user earns will not apply to their referral scores. When used correctly, it can be used to prevent points farming.

applies_to_points_score
boolean
default: "true"

When this field is set to false, the points issued here will not apply to their points score (it will automatically not apply to their referral score either). When used correctly, it can be used to mark someone’s progress to issue an achievement (without issuing a points change).

The client_season and added_by fields are visible via the gql queries but cannot be manually modified through mutations.