Deactivate Whitelisted Contract
The "Deactivate Whitelisted Contract" API endpoint provided by Krypcore allows users to deactivate (remove) a whitelisted contract under a given instance.
API Specification
Deactivate Whitelisted Contract
POST
https://api.krypcore.com/api/v0/gasless/deactivateWhitelistedContract
Update Configured Gas Limit under the given instance.
Headers
Name | Type | Description |
---|---|---|
Authorization* | String | User Auth key obtained |
Request Body
Name | Type | Description |
---|---|---|
contractAddress* | String | Address of the contract to be deactivated from the whitelist. |
dAppId* | String | Dapp ID associated with the application. |
{
"data": null,
"message": "Whitelisted contract deactivated successfully",
"status": true
}
{
"message": "Invalid API key in request"
}
Take a look at how you might call this method using our official libraries, or via curl
curl --location 'https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract' \
--header 'Authorization: 81d4a427-xxxx-xxxx-xxxx-f8482816e872' \
--header 'Content-Type: application/json' \
--data '{
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"
}'
import requests
import json
url = "https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract"
payload = json.dumps({
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"
})
headers = {
'Authorization': '81d4a427-xxxx-xxxx-xxxx-f8482816e872',
'Content-Type': 'application/json'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
import requests
import json
url = "https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract"
payload = json.dumps({
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"
})
headers = {
'Authorization': '81d4a427-xxxx-xxxx-xxxx-f8482816e872',
'Content-Type': 'application/json'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
import requests
import json
url = "https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract"
payload = json.dumps({
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"
})
headers = {
'Authorization': '81d4a427-xxxx-xxxx-xxxx-f8482816e872',
'Content-Type': 'application/json'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract"
method := "POST"
payload := strings.NewReader(`{`+"
"+`
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",`+"
"+`
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"`+"
"+`
}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "81d4a427-xxxx-xxxx-xxxx-f8482816e872")
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract"
method := "POST"
payload := strings.NewReader(`{`+"
"+`
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",`+"
"+`
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"`+"
"+`
}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "81d4a427-xxxx-xxxx-xxxx-f8482816e872")
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract"
method := "POST"
payload := strings.NewReader(`{`+"
"+`
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",`+"
"+`
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"`+"
"+`
}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "81d4a427-xxxx-xxxx-xxxx-f8482816e872")
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
} != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "81d4a427-xxxx-xxxx-xxxx-f8482816e872")
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://web3-proxy-dev.krypcore.com/api/v0/gasless/deactivateWhitelistedContract"
method := "POST"
payload := strings.NewReader(`{`+"
"+`
"contractAddress": "0x0E762313219aE4dD7C674367a39901Ac1cxxxxxx",`+"
"+`
"dAppId": "DEV_TT-1_XENO_231_xxxxxxx"`+"
"+`
}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "81d4a427-xxxx-xxxx-xxxx-f8482816e872")
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}
Last updated