SSpiderIQ
SSpiderIQ

Docs / api-reference/dashboard

Dashboard

11 endpoints from the published OpenAPI import.

GET/api/v1/dashboard/me

Get Current User

Return the current authenticated dashboard user's info and role.

Try it

Examples

cURL
curl -X GET 'https://spideriq.ai/api/v1/dashboard/me' \
  -H 'Authorization: Bearer <token>'
Python
import httpx

resp = httpx.get(
    "https://spideriq.ai/api/v1/dashboard/me",
    headers={"Authorization": "Bearer <token>"},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/me", {
  method: "GET",
  headers: { "Authorization": "Bearer <token>" }
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
)

func main() {
	req, _ := http.NewRequest("GET", "https://spideriq.ai/api/v1/dashboard/me", nil)
	req.Header.Set("Authorization", "Bearer <token>")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
PATCH/api/v1/dashboard/me/preferences

Update My Preferences

Update per-user UI preferences for the current dashboard user.

Today the only field is event_sounds_enabled, the Live Theater audio toggle (Stage D). Returns the full updated /me payload so the client can refresh its cache from a single response.

Try it

Examples

cURL
curl -X PATCH 'https://spideriq.ai/api/v1/dashboard/me/preferences' \
  -H 'Authorization: Bearer <token>' \
  -H 'Content-Type: application/json' \
  -d '{
  "event_sounds_enabled": true
}'
Python
import httpx

resp = httpx.patch(
    "https://spideriq.ai/api/v1/dashboard/me/preferences",
    headers={"Authorization": "Bearer <token>", "Content-Type": "application/json"},
    json={"event_sounds_enabled": true},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/me/preferences", {
  method: "PATCH",
  headers: { "Authorization": "Bearer <token>", "Content-Type": "application/json" },
  body: JSON.stringify({"event_sounds_enabled": true})
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{"event_sounds_enabled": true}`)
	req, _ := http.NewRequest("PATCH", "https://spideriq.ai/api/v1/dashboard/me/preferences", body)
	req.Header.Set("Authorization", "Bearer <token>")
	req.Header.Set("Content-Type", "application/json")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
422Validation Error
GET/api/v1/dashboard/users

List Dashboard Users

List all dashboard users with their brand memberships. Super admin only.

Parameters

NameInTypeRequiredDescription
rolequeryanyfalse
searchqueryanyfalse
Try it
Query

Examples

cURL
curl -X GET 'https://spideriq.ai/api/v1/dashboard/users' \
  -H 'Authorization: Bearer <token>'
Python
import httpx

resp = httpx.get(
    "https://spideriq.ai/api/v1/dashboard/users",
    headers={"Authorization": "Bearer <token>"},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users", {
  method: "GET",
  headers: { "Authorization": "Bearer <token>" }
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
)

func main() {
	req, _ := http.NewRequest("GET", "https://spideriq.ai/api/v1/dashboard/users", nil)
	req.Header.Set("Authorization", "Bearer <token>")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
422Validation Error
POST/api/v1/dashboard/users

Create Dashboard User

Provision a Better Auth user for dashboard access. Super admin only.

Try it

Examples

cURL
curl -X POST 'https://spideriq.ai/api/v1/dashboard/users' \
  -H 'Authorization: Bearer <token>' \
  -H 'Content-Type: application/json' \
  -d '{
  "user_id": "string",
  "role": "client_user",
  "client_id": "string",
  "permissions": [
    "string"
  ]
}'
Python
import httpx

resp = httpx.post(
    "https://spideriq.ai/api/v1/dashboard/users",
    headers={"Authorization": "Bearer <token>", "Content-Type": "application/json"},
    json={"user_id": "string", "role": "client_user", "client_id": "string", "permissions": ["string"]},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users", {
  method: "POST",
  headers: { "Authorization": "Bearer <token>", "Content-Type": "application/json" },
  body: JSON.stringify({"user_id": "string", "role": "client_user", "client_id": "string", "permissions": ["string"]})
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{"user_id": "string", "role": "client_user", "client_id": "string", "permissions": ["string"]}`)
	req, _ := http.NewRequest("POST", "https://spideriq.ai/api/v1/dashboard/users", body)
	req.Header.Set("Authorization", "Bearer <token>")
	req.Header.Set("Content-Type", "application/json")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
201Successful Response
422Validation Error
PATCH/api/v1/dashboard/users/{user_id}

Update Dashboard User

Update a dashboard user's role, permissions, or active status. Super admin only.

Parameters

NameInTypeRequiredDescription
user_idpathstringtrue
Try it
Query

Examples

cURL
curl -X PATCH 'https://spideriq.ai/api/v1/dashboard/users/{user_id}' \
  -H 'Authorization: Bearer <token>' \
  -H 'Content-Type: application/json' \
  -d '{
  "role": "string",
  "client_id": "string",
  "permissions": [
    "string"
  ],
  "is_active": true
}'
Python
import httpx

resp = httpx.patch(
    "https://spideriq.ai/api/v1/dashboard/users/{user_id}",
    headers={"Authorization": "Bearer <token>", "Content-Type": "application/json"},
    json={"role": "string", "client_id": "string", "permissions": ["string"], "is_active": true},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users/{user_id}", {
  method: "PATCH",
  headers: { "Authorization": "Bearer <token>", "Content-Type": "application/json" },
  body: JSON.stringify({"role": "string", "client_id": "string", "permissions": ["string"], "is_active": true})
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{"role": "string", "client_id": "string", "permissions": ["string"], "is_active": true}`)
	req, _ := http.NewRequest("PATCH", "https://spideriq.ai/api/v1/dashboard/users/{user_id}", body)
	req.Header.Set("Authorization", "Bearer <token>")
	req.Header.Set("Content-Type", "application/json")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
422Validation Error
DELETE/api/v1/dashboard/users/{user_id}

Delete Dashboard User

Fully remove a user from the platform. Super admin only.

Removing a user in /admin/users used to delete ONLY the dashboard_users row, which hid the user from the admin list while leaving them an active brand member with live API tokens. This does the full cascade in one transaction:

  1. Revoke every live agent token (PAT) issued to the user's email.
  2. Mark the user's pending/active PAT requests revoked.
  3. Drop every brand membership (removes them from ALL brands).
  4. Delete the user_profiles row.
  5. Delete the dashboard_users row (dashboard access).
  6. Delete the Better Auth user row (cascades account + session).

Tokens are revoked (not deleted) so their billing/usage history survives. Identity/membership rows are hard-deleted, freeing the email for re-invite.

Parameters

NameInTypeRequiredDescription
user_idpathstringtrue
Try it
Query

Examples

cURL
curl -X DELETE 'https://spideriq.ai/api/v1/dashboard/users/{user_id}' \
  -H 'Authorization: Bearer <token>'
Python
import httpx

resp = httpx.delete(
    "https://spideriq.ai/api/v1/dashboard/users/{user_id}",
    headers={"Authorization": "Bearer <token>"},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users/{user_id}", {
  method: "DELETE",
  headers: { "Authorization": "Bearer <token>" }
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
)

func main() {
	req, _ := http.NewRequest("DELETE", "https://spideriq.ai/api/v1/dashboard/users/{user_id}", nil)
	req.Header.Set("Authorization", "Bearer <token>")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
422Validation Error
POST/api/v1/dashboard/users/{user_id}/brands

Add User To Brand

Directly add a user to a brand. Super admin only.

Unlike the invitation flow, this immediately adds the user as a member.

Parameters

NameInTypeRequiredDescription
user_idpathstringtrue
Try it
Query

Examples

cURL
curl -X POST 'https://spideriq.ai/api/v1/dashboard/users/{user_id}/brands' \
  -H 'Authorization: Bearer <token>' \
  -H 'Content-Type: application/json' \
  -d '{
  "user_id": "string",
  "brand_id": 0,
  "role": "member"
}'
Python
import httpx

resp = httpx.post(
    "https://spideriq.ai/api/v1/dashboard/users/{user_id}/brands",
    headers={"Authorization": "Bearer <token>", "Content-Type": "application/json"},
    json={"user_id": "string", "brand_id": 0, "role": "member"},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users/{user_id}/brands", {
  method: "POST",
  headers: { "Authorization": "Bearer <token>", "Content-Type": "application/json" },
  body: JSON.stringify({"user_id": "string", "brand_id": 0, "role": "member"})
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{"user_id": "string", "brand_id": 0, "role": "member"}`)
	req, _ := http.NewRequest("POST", "https://spideriq.ai/api/v1/dashboard/users/{user_id}/brands", body)
	req.Header.Set("Authorization", "Bearer <token>")
	req.Header.Set("Content-Type", "application/json")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
201Successful Response
422Validation Error
POST/api/v1/dashboard/credentials/regenerate

Regenerate Client Credentials

Regenerate API credentials for the current user's client.

  • brand_admin and client_user: Regenerates their own client's credentials
  • super_admin: Must not use this endpoint (they don't have a client)

Returns new credentials. Save them immediately - they cannot be retrieved again.

Try it

Examples

cURL
curl -X POST 'https://spideriq.ai/api/v1/dashboard/credentials/regenerate' \
  -H 'Authorization: Bearer <token>'
Python
import httpx

resp = httpx.post(
    "https://spideriq.ai/api/v1/dashboard/credentials/regenerate",
    headers={"Authorization": "Bearer <token>"},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/credentials/regenerate", {
  method: "POST",
  headers: { "Authorization": "Bearer <token>" }
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
)

func main() {
	req, _ := http.NewRequest("POST", "https://spideriq.ai/api/v1/dashboard/credentials/regenerate", nil)
	req.Header.Set("Authorization", "Bearer <token>")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
GET/api/v1/dashboard/users/{user_id}/generate-password

Generate Password For User

Generate a secure random password. Super admin only.

Returns a 16-character password with mixed case, digits, and symbols. The password is NOT automatically set - use /set-password to apply it.

Parameters

NameInTypeRequiredDescription
user_idpathstringtrue
Try it
Query

Examples

cURL
curl -X GET 'https://spideriq.ai/api/v1/dashboard/users/{user_id}/generate-password' \
  -H 'Authorization: Bearer <token>'
Python
import httpx

resp = httpx.get(
    "https://spideriq.ai/api/v1/dashboard/users/{user_id}/generate-password",
    headers={"Authorization": "Bearer <token>"},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users/{user_id}/generate-password", {
  method: "GET",
  headers: { "Authorization": "Bearer <token>" }
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
)

func main() {
	req, _ := http.NewRequest("GET", "https://spideriq.ai/api/v1/dashboard/users/{user_id}/generate-password", nil)
	req.Header.Set("Authorization", "Bearer <token>")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
422Validation Error
POST/api/v1/dashboard/users/{user_id}/set-password

Set User Password

Set a user's password directly. Super admin only.

Updates the password in Better Auth's account table using scrypt hashing. Optionally sends the new password to the user via email.

Parameters

NameInTypeRequiredDescription
user_idpathstringtrue
Try it
Query

Examples

cURL
curl -X POST 'https://spideriq.ai/api/v1/dashboard/users/{user_id}/set-password' \
  -H 'Authorization: Bearer <token>' \
  -H 'Content-Type: application/json' \
  -d '{
  "new_password": "string",
  "send_email": false
}'
Python
import httpx

resp = httpx.post(
    "https://spideriq.ai/api/v1/dashboard/users/{user_id}/set-password",
    headers={"Authorization": "Bearer <token>", "Content-Type": "application/json"},
    json={"new_password": "string", "send_email": false},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users/{user_id}/set-password", {
  method: "POST",
  headers: { "Authorization": "Bearer <token>", "Content-Type": "application/json" },
  body: JSON.stringify({"new_password": "string", "send_email": false})
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
	"strings"
)

func main() {
	body := strings.NewReader(`{"new_password": "string", "send_email": false}`)
	req, _ := http.NewRequest("POST", "https://spideriq.ai/api/v1/dashboard/users/{user_id}/set-password", body)
	req.Header.Set("Authorization", "Bearer <token>")
	req.Header.Set("Content-Type", "application/json")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
422Validation Error
POST/api/v1/dashboard/users/{user_id}/trigger-reset

Trigger Password Reset

Trigger a password reset email for a user. Super admin only.

Creates a reset token and sends the password reset email to the user.

Parameters

NameInTypeRequiredDescription
user_idpathstringtrue
Try it
Query

Examples

cURL
curl -X POST 'https://spideriq.ai/api/v1/dashboard/users/{user_id}/trigger-reset' \
  -H 'Authorization: Bearer <token>'
Python
import httpx

resp = httpx.post(
    "https://spideriq.ai/api/v1/dashboard/users/{user_id}/trigger-reset",
    headers={"Authorization": "Bearer <token>"},
)
resp.raise_for_status()
print(resp.json())
JavaScript
const resp = await fetch("https://spideriq.ai/api/v1/dashboard/users/{user_id}/trigger-reset", {
  method: "POST",
  headers: { "Authorization": "Bearer <token>" }
});
const data = await resp.json();
console.log(data);
Go
package main

import (
	"net/http"
)

func main() {
	req, _ := http.NewRequest("POST", "https://spideriq.ai/api/v1/dashboard/users/{user_id}/trigger-reset", nil)
	req.Header.Set("Authorization", "Bearer <token>")
	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
}

Responses

StatusDescription
200Successful Response
422Validation Error