Auth-Sessions
Delete AuthSession
Delete an AuthSession by ID.
DELETE
/
{workspaceId}
/
projects
/
{projectName}
/
auth-sessions
/
{authSessionId}
deleteAuthSession
import { IntunedClient } from "@intuned/client";
const client = new IntunedClient({
workspaceId: "123e4567-e89b-12d3-a456-426614174000",
apiKey: process.env["INTUNED_API_KEY"] ?? "",
});
async function run() {
await client.projects.authSessions.delete(
"my-project",
"<id>",
);
console.log("Request completed successfully");
}
run();from intuned_client import IntunedClient
import os
with IntunedClient(
workspace_id="123e4567-e89b-12d3-a456-426614174000",
api_key=os.getenv("INTUNED_API_KEY", ""),
) as client:
client.projects.auth_sessions.delete(
project_name="my-project",
auth_session_id="auth-session-123",
)
print("Request completed successfully")curl --request DELETE \
--url https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId} \
--header 'x-api-key: <api-key>'const options = {method: 'DELETE', headers: {'x-api-key': '<api-key>'}};
fetch('https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}', 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://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyAuthorizations
API Key used to authenticate your requests. How to create one.
Path Parameters
Your workspace ID. How to find it?
The name you assigned when creating the Project.
Authentication session ID. You can obtain it from the AuthSessions tab in your project details.
Response
204
Deleted successfully
⌘I
deleteAuthSession
import { IntunedClient } from "@intuned/client";
const client = new IntunedClient({
workspaceId: "123e4567-e89b-12d3-a456-426614174000",
apiKey: process.env["INTUNED_API_KEY"] ?? "",
});
async function run() {
await client.projects.authSessions.delete(
"my-project",
"<id>",
);
console.log("Request completed successfully");
}
run();from intuned_client import IntunedClient
import os
with IntunedClient(
workspace_id="123e4567-e89b-12d3-a456-426614174000",
api_key=os.getenv("INTUNED_API_KEY", ""),
) as client:
client.projects.auth_sessions.delete(
project_name="my-project",
auth_session_id="auth-session-123",
)
print("Request completed successfully")curl --request DELETE \
--url https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId} \
--header 'x-api-key: <api-key>'const options = {method: 'DELETE', headers: {'x-api-key': '<api-key>'}};
fetch('https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}', 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://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$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://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.intuned.io/api/v1/workspace/{workspaceId}/projects/{projectName}/auth-sessions/{authSessionId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body