mirror of
https://github.com/status-im/status-go.git
synced 2025-02-16 16:56:53 +00:00
fix: add supported chains to OpenSea
This commit is contained in:
parent
e131d738bd
commit
ff755a1176
6
services/wallet/thirdparty/opensea/client.go
vendored
6
services/wallet/thirdparty/opensea/client.go
vendored
@ -35,15 +35,15 @@ const ChainIDRequiringAPIKey = 1
|
|||||||
|
|
||||||
func getbaseURL(chainID uint64) (string, error) {
|
func getbaseURL(chainID uint64) (string, error) {
|
||||||
switch chainID {
|
switch chainID {
|
||||||
case 1:
|
case 1, 10, 42161:
|
||||||
return "https://api.opensea.io/api/v1", nil
|
return "https://api.opensea.io/api/v1", nil
|
||||||
case 4:
|
case 4:
|
||||||
return "https://rinkeby-api.opensea.io/api/v1", nil
|
return "https://rinkeby-api.opensea.io/api/v1", nil
|
||||||
case 5:
|
case 5, 420, 421613:
|
||||||
return "https://testnets-api.opensea.io/api/v1", nil
|
return "https://testnets-api.opensea.io/api/v1", nil
|
||||||
}
|
}
|
||||||
|
|
||||||
return "", fmt.Errorf("chainID not supported")
|
return "", fmt.Errorf("chainID not supported: %d", chainID)
|
||||||
}
|
}
|
||||||
|
|
||||||
var OpenseaClientInstances = make(map[uint64]*Client)
|
var OpenseaClientInstances = make(map[uint64]*Client)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user