Backend Integration
Fetching Predicate Attestations requires an API key that must be secured. Like most cases, using a passthrough proxy is best practice here.
Mental model
- With specific transaction information, your backend requests the PredicateAPI for an attestation.
- The PredicateAPI returns a message detailing if the request is compliant and a corresponding attestation.
- Your frontend includes that message when calling a predicated contract function.
- EVM
- SVM
Backend Integration
Store your API key on the server, call the Predicate API, and return the attestation to the client. The examples show representative payloads; adapt the function signature/args for your app.Example Backend Proxy (EVM)
Frontend Integration
Fetch the attestation from your backend and pass it to your predicated function.Frontend (EVM)
