Request
Head over to the run function in the interactive docs. Press the “Try it out” button and copy-paste this request body:
{
"slug": "price.dex-blended",
"chainId": 1,
"blockNumber": "latest",
"input": {"address" : "0x7Fc66500c84A76Ad7e9c93437bFc5Ac33E2DDaE9"}
}
The slug is the unique ID for the model. The input block includes any model-specific parameters. In this case the model only requires one parameter, address, the value is the contract address of the AAVE token.
Note that an optional parameter, version, can be used to call a specific version of the model. This should rarely if ever be used. Omitting this parameter guaranties that the most up-to-date version of the model is run.
curl -X 'POST' \
'https://gateway.credmark.com/v1/model/run' \
-H 'Authorization: Bearer <API key>' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '{
"slug": "price.dex-blended",
"chainId": 1,
"blockNumber": "latest",
"input": {"address" : "0x7Fc66500c84A76Ad7e9c93437bFc5Ac33E2DDaE9"}
}'
Last modified 1yr ago