We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am currently working with AVNU API and there is a method that provides a TypedData JSON, as follows:
{"types":{"StarknetDomain":[{"name":"name","type":"shortstring"},{"name":"version","type":"shortstring"},{"name":"chainId","type":"shortstring"},{"name":"revision","type":"shortstring"}],"OutsideExecution":[{"name":"Caller","type":"ContractAddress"},{"name":"Nonce","type":"felt"},{"name":"Execute After","type":"u128"},{"name":"Execute Before","type":"u128"},{"name":"Calls","type":"Call*"}],"Call":[{"name":"To","type":"ContractAddress"},{"name":"Selector","type":"selector"},{"name":"Calldata","type":"felt*"}]},"primaryType":"OutsideExecution","domain":{"name":"Account.execute......
And I perform the classic method for umarshelling in Go as follows:
var buildResponse typed.TypedData err = json.Unmarshal(body, &buildResponse) if err != nil { log.Fatalf("Failed to unmarshal the response body: %v", err) return typed.TypedData{}, err }
Seems like there is no JSON like this for unmarshelling:
type GasTokenPrice struct { TokenAddress string json:"tokenAddress" GasFeesInGasToken string json:"gasFeesInGasToken" GasFeesInUsd float64 json:"gasFeesInUsd" }
json:"tokenAddress"
json:"gasFeesInGasToken"
json:"gasFeesInUsd"
Is there another way to perform this unmarshal?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I am currently working with AVNU API and there is a method that provides a TypedData JSON, as follows:
{"types":{"StarknetDomain":[{"name":"name","type":"shortstring"},{"name":"version","type":"shortstring"},{"name":"chainId","type":"shortstring"},{"name":"revision","type":"shortstring"}],"OutsideExecution":[{"name":"Caller","type":"ContractAddress"},{"name":"Nonce","type":"felt"},{"name":"Execute After","type":"u128"},{"name":"Execute Before","type":"u128"},{"name":"Calls","type":"Call*"}],"Call":[{"name":"To","type":"ContractAddress"},{"name":"Selector","type":"selector"},{"name":"Calldata","type":"felt*"}]},"primaryType":"OutsideExecution","domain":{"name":"Account.execute......
And I perform the classic method for umarshelling in Go as follows:
var buildResponse typed.TypedData
err = json.Unmarshal(body, &buildResponse)
if err != nil {
log.Fatalf("Failed to unmarshal the response body: %v", err)
return typed.TypedData{}, err
}
Seems like there is no JSON like this for unmarshelling:
type GasTokenPrice struct {
TokenAddress string
json:"tokenAddress"
GasFeesInGasToken string
json:"gasFeesInGasToken"
GasFeesInUsd float64
json:"gasFeesInUsd"
}
Is there another way to perform this unmarshal?
The text was updated successfully, but these errors were encountered: