Single Dimensional Config
Learn how to configure REST Single-Dimensional Credential
Overview
REST Single-Dimensional Credential allows you to fetch user data via RESTful APIs and validate user eligibility based on a single condition. It is suitable for simple use cases such as whitelist checks or balance validations.
Config process
1. Basic Config
- ID Type
ID Type
provides various identity options, including social accounts, blockchain addresses, and other unique identifiers.
- Title
Give your credential an enticing title.
- Credential Source
Choose REST
type and select GET
or POST
based on your API request type.
- Type
Choose Single Dimension
2. Configure API
- Input Endpoint
GET Request Example:
POST Request Example:
- Add Headers (Optional)
- Input Body (For POST Requests Only):
3. Test API Response
- Input a test address, send the request, and confirm whether the response is correct.
- The response must be in JSON format. Example:
4. Write Expressions
-
Whitelist Validation:
-
Token Balance Validation:
-
Combined Condition Validation:
5. Description
Description of the certificate, supports rich text input, maximum 200 characters.
6. Call-to-Action Link
Guide users to specific operation pages to complete interactive tasks.
7. Participation End Time && Update Frequency (Optional)
- Participation End Time:
Control the time range of the credential, prohibiting new validations after the deadline.
- Update Frequency:
Remind users of the frequency of API data source updates, such as once a day or once every two days.
Example
Polygon OAT Holder
- Endpoint
- Request Type
GET
- Headers
- Response
- Expression
ETH Balance Holder
- Endpoint
- Request Type
POST
- Headers
No header
- Body
- Response
- Expression
General NFT Holder
- Endpoint
- Request Type
POST
- Headers
No header
- Body
- Response
- Expression