Documentation Index
Fetch the complete documentation index at: https://docs.galxe.com/llms.txt
Use this file to discover all available pages before exploring further.
Overview
The Credential API provides read-only access to verify user eligibility and query credential information.
Core Queries
query GetCredential($credId: ID!) {
credential(id: $credId) {
id
name
description
credType
credSource
chain
referenceLink
itemCount
lastUpdate
lastSync
syncStatus
curatorSpace {
id
name
}
}
}
Check User Eligibility
query CheckEligibility($credId: ID!, $address: String!, $campaignId: ID) {
credential(id: $credId) {
id
name
eligible(address: $address, campaignId: $campaignId)
credType
credSource
syncStatus
lastSync
}
}
Variables:
{
"credId": "312969464",
"address": "0x1234567890123456789012345678901234567890",
"campaignId": "GChdWUjXX3"
}
Response:
{
"data": {
"credential": {
"id": "312969464",
"name": "Twitter Follower Verification",
"eligible": 1,
"credType": "TWITTER",
"credSource": "TWITTER_FOLLOW",
"syncStatus": "SYNCED",
"lastSync": 1699200000
}
}
}
Eligibility Values:
1 - User has the credential
0 - User does not have the credential
Field Reference
Key Fields
| Field | Type | Description |
|---|
id | ID! | Credential’s unique identifier |
name | String! | Human-readable credential name |
credType | CredType! | Credential platform/type |
credSource | CredSource! | Verification method |
eligible(address, campaignId) | Int | User eligibility check (0 or 1) |
syncStatus | SyncStatus! | Data synchronization status |
itemCount | Int | Total number of credential holders |
Credential Types
| Type | Description |
|---|
TWITTER | Twitter account verification |
DISCORD | Discord membership verification |
EVM_ADDRESS | Ethereum-compatible addresses |
SOLANA_ADDRESS | Solana wallet addresses |
GITHUB | GitHub account verification |
EMAIL | Email address verification |
Credential Sources
| Source | Description |
|---|
TWITTER_FOLLOW | Twitter follow verification |
DISCORD_MEMBER | Discord server membership |
CONTRACT_NFT_HOLDER | NFT ownership verification |
WALLET_BALANCE | Token balance requirements |
QUIZ | Quiz completion verification |
API | Custom API verification |
Sync Status
| Status | Description |
|---|
SYNCED | Data is current and reliable |
SYNCING | Data is being updated, may be stale |
Integration Patterns
Basic Verification
curl -X POST https://graphigo-business.prd.galaxy.eco/query \
-H "Content-Type: application/json" \
-H "access-token: YOUR_ACCESS_TOKEN" \
-d '{
"query": "query CheckEligibility($credId: ID!, $address: String!) { credential(id: $credId) { name eligible(address: $address) syncStatus } }",
"variables": { "credId": "312969464", "address": "0x..." }
}'
Quest-Specific Context
When checking eligibility for a specific quest, include the campaignId parameter:
eligible(address: $address, campaignId: $campaignId)
Best Practices
- Check Sync Status: Always verify
syncStatus is SYNCED before relying on eligibility results
- Handle Quest Context: Use
campaignId parameter for quest-specific verifications
- Cache Results: Cache eligibility results for 5-10 minutes to reduce API calls
- Error Handling: Handle invalid credential IDs and network errors gracefully
Common Errors
| Error | Cause | Solution |
|---|
Credential not found | Invalid credential ID | Verify credential ID exists |
Address not provided | Missing address parameter | Include user address in query |
Rate limit exceeded | Too many requests | Implement retry logic |
Invalid access token | Bad/expired token | Regenerate access token |
Next Steps