Revoke a key
curl --request DELETE \
--url https://agent.lanesurf.com/v1/keys/{key_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://agent.lanesurf.com/v1/keys/{key_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://agent.lanesurf.com/v1/keys/{key_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://agent.lanesurf.com/v1/keys/{key_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://agent.lanesurf.com/v1/keys/{key_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://agent.lanesurf.com/v1/keys/{key_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://agent.lanesurf.com/v1/keys/{key_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"revoked": true,
"key_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key_prefix": "<string>",
"was_current_key": true,
"next_step": "<string>"
}{
"error": "invalid API key",
"code": "invalid_api_key"
}{
"error": "invalid API key",
"code": "invalid_api_key",
"missing": [
"<string>"
],
"next_step": "<string>",
"current_rate": 123,
"request_id": "req_0192f3a4-7b1c-7d2e-9f00-1a2b3c4d5e6f"
}{
"error": "invalid API key",
"code": "invalid_api_key",
"missing": [
"<string>"
],
"next_step": "<string>",
"current_rate": 123,
"request_id": "req_0192f3a4-7b1c-7d2e-9f00-1a2b3c4d5e6f"
}{
"error": "too many requests for this API key; slow down",
"code": "rate_limited"
}{
"error": "a Lanesurf system behind the API failed; try again later",
"code": "upstream_error"
}Sign-up, keys and setup API
Revoke a key
Turn off a key for good.
DELETE
/
v1
/
keys
/
{key_id}
Revoke a key
curl --request DELETE \
--url https://agent.lanesurf.com/v1/keys/{key_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://agent.lanesurf.com/v1/keys/{key_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://agent.lanesurf.com/v1/keys/{key_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://agent.lanesurf.com/v1/keys/{key_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://agent.lanesurf.com/v1/keys/{key_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://agent.lanesurf.com/v1/keys/{key_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://agent.lanesurf.com/v1/keys/{key_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"revoked": true,
"key_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"key_prefix": "<string>",
"was_current_key": true,
"next_step": "<string>"
}{
"error": "invalid API key",
"code": "invalid_api_key"
}{
"error": "invalid API key",
"code": "invalid_api_key",
"missing": [
"<string>"
],
"next_step": "<string>",
"current_rate": 123,
"request_id": "req_0192f3a4-7b1c-7d2e-9f00-1a2b3c4d5e6f"
}{
"error": "invalid API key",
"code": "invalid_api_key",
"missing": [
"<string>"
],
"next_step": "<string>",
"current_rate": 123,
"request_id": "req_0192f3a4-7b1c-7d2e-9f00-1a2b3c4d5e6f"
}{
"error": "too many requests for this API key; slow down",
"code": "rate_limited"
}{
"error": "a Lanesurf system behind the API failed; try again later",
"code": "upstream_error"
}Any key can revoke itself. Only the key that signed a brokerage up through the API can revoke
teammates’ keys; a brokerage Lanesurf onboarded removes teammates in the Lanesurf dashboard. Every
app signed in with the key is signed out.
Authorizations
One key per broker rep or per carrier signup. Keep it secret.
Path Parameters
Response
Revoked.
Available options:
true true if you revoked the key making this request: it no longer works.
For the agent. Exactly what to do next and which MCP tool to call (REST path in brackets).