Logout
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({refreshToken: '<string>'})
};
fetch('https://gp-auth-module.prod.gnosispay.com/auth/logout', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://gp-auth-module.prod.gnosispay.com/auth/logout \
--header 'Content-Type: application/json' \
--data '
{
"refreshToken": "<string>"
}
'import requests
url = "https://gp-auth-module.prod.gnosispay.com/auth/logout"
payload = { "refreshToken": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://gp-auth-module.prod.gnosispay.com/auth/logout"
payload := strings.NewReader("{\n \"refreshToken\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://gp-auth-module.prod.gnosispay.com/auth/logout")
.header("Content-Type", "application/json")
.body("{\n \"refreshToken\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://gp-auth-module.prod.gnosispay.com/auth/logout")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"refreshToken\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true
}{
"success": false,
"error": {
"name": "ValidationError",
"message": "<string>"
}
}Auth
Logout
Invalidate the current session by revoking all refresh tokens in the token family. The client is responsible for deleting the refresh token from its storage.
POST
/
auth
/
logout
Logout
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({refreshToken: '<string>'})
};
fetch('https://gp-auth-module.prod.gnosispay.com/auth/logout', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://gp-auth-module.prod.gnosispay.com/auth/logout \
--header 'Content-Type: application/json' \
--data '
{
"refreshToken": "<string>"
}
'import requests
url = "https://gp-auth-module.prod.gnosispay.com/auth/logout"
payload = { "refreshToken": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://gp-auth-module.prod.gnosispay.com/auth/logout"
payload := strings.NewReader("{\n \"refreshToken\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://gp-auth-module.prod.gnosispay.com/auth/logout")
.header("Content-Type", "application/json")
.body("{\n \"refreshToken\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://gp-auth-module.prod.gnosispay.com/auth/logout")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"refreshToken\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"success": true
}{
"success": false,
"error": {
"name": "ValidationError",
"message": "<string>"
}
}⌘I