Overview

API credentials allow you to push user data to Galxe via the API, suitable for simple use cases such as whitelist checks.

If you want to understand the workflow and considerations of API credentials, please refer to the introduction

Config process

1. Finding the Config in Task Settings

The option to configure API credential can be found in step 3, Task Settings of quest creation on the Galxe Dashboard, under the Import Your Own Data task type.

2. Basic Config

  • ID Type

ID Type provides various identity options, including social accounts, blockchain addresses, and other unique identifiers. Choose the one appropriate to your task.

  • Title

Give your credential a descriptive title relevant to the task at hand.

  • Credential Source

Choose API type

  • Description:

Description of the task, supports rich text input, maximum 200 characters.

  • Call-to-Action Link:

Guide users to the specific URL where they can complete the task.

  • Participation End Time(Optional):

Control the time range of the credential, prohibiting new verifications after the deadline.

  • Update Frequency (Optional):

Remind users of the frequency of API data source updates, such as once a day or once every two days.

3. API Update

Use the Galxe GraphQL API to push data to the credential.

  • GraphQL Example:
mutation {
  credentialItems(
    input: {
      credId: "312"
      operation: APPEND
      items: [
        "0x111fd6240381af2c5f1a9e27f282bae8b92b257"
        "0x222dde76Cf5752f2bc1DC798BA1369dcA49d7c79"
        "0x333eC1a5d0BC3C4291aeb962CBda49677E9a9FcB"
        "0x444022af64bfc0f59ce1069e4ab51aa15148e60b"
        "0x55526ef96b12fba7a507afba39bdfc78e0039742"
        "0x6662c6b59e87b302b43400303427acd50f8071e6"
        "0x777742ee649ee36edcf5ac9a97df34333a97fd24"
        "0x8886b92fda46b8d9d33ca28d8837e1661edf8b97"
        "0x999886e265cf2ec39f8868d7b6c67ab78e027736"
      ]
    }
  ) {
    eligible(address:"0x999886e265cf2ec39f8868d7b6c67ab78e027736")
  }
}

  • Code Examples: