curl --request GET \
--url 'https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0'
import requests
response = requests.get(
"https://api.sprinter.tech/credit/earn/claim",
params={
"owner": "0xUSER",
"receiver": "0xRECEIVER",
"asset": "0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61",
"chain": "eip155:8453",
"claimRequestId": "0"
}
)
print(response.json())
const response = await fetch(
"https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0"
);
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
resp, _ := http.Get("https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0")
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"calls": [
{
"chain": "8453",
"to": "0x1234567890abcdef1234567890abcdef12345678",
"data": "0xa9059cbb000000000000000000000000000000000000000000000000000000000005f5e100",
"value": "0"
}
]
}
Credit Advanced
Claim from Earn Vault
Creates list of contract calls to Claim a position from an earn vault, converting vault shares back to the underlying asset.
GET
/
credit
/
earn
/
claim
curl --request GET \
--url 'https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0'
import requests
response = requests.get(
"https://api.sprinter.tech/credit/earn/claim",
params={
"owner": "0xUSER",
"receiver": "0xRECEIVER",
"asset": "0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61",
"chain": "eip155:8453",
"claimRequestId": "0"
}
)
print(response.json())
const response = await fetch(
"https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0"
);
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
resp, _ := http.Get("https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0")
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"calls": [
{
"chain": "8453",
"to": "0x1234567890abcdef1234567890abcdef12345678",
"data": "0xa9059cbb000000000000000000000000000000000000000000000000000000000005f5e100",
"value": "0"
}
]
}
The
chain parameter uses CAIP-2 format: eip155:<chainId>. For example, eip155:8453 for Base. See Supported Chains for the full list.curl --request GET \
--url 'https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0'
import requests
response = requests.get(
"https://api.sprinter.tech/credit/earn/claim",
params={
"owner": "0xUSER",
"receiver": "0xRECEIVER",
"asset": "0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61",
"chain": "eip155:8453",
"claimRequestId": "0"
}
)
print(response.json())
const response = await fetch(
"https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0"
);
const data = await response.json();
console.log(data);
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
resp, _ := http.Get("https://api.sprinter.tech/credit/earn/claim?owner=0xUSER&receiver=0xRECEIVER&asset=0xeE8F4eC5672F09119b96Ab6fB59C27E1b7e44b61&chain=eip155:8453&claimRequestId=0")
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}
{
"calls": [
{
"chain": "8453",
"to": "0x1234567890abcdef1234567890abcdef12345678",
"data": "0xa9059cbb000000000000000000000000000000000000000000000000000000000005f5e100",
"value": "0"
}
]
}
Machine-readable API spec: OpenAPI JSON | Swagger UI
Query Parameters
Owner address that holds the vault shares
Address that will receive the Claimed underlying tokens
Vault shares token address
Chain ID in CAIP format
claimRequestId
Response
OK
List of contract calls to execute the Claim
Show child attributes
Show child attributes
⌘I