Archivist AI Factions API
The factions API from Archivist AI — 3 operation(s) for factions.
The factions API from Archivist AI — 3 operation(s) for factions.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/myarchivist-ai:myarchivist-ai-factions-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: Archivist Public Factions API
description: Public API for Archivist - Tabletop RPG Campaign Management
version: 1.0.0
tags:
- name: factions
paths:
/v1/factions:
get:
tags:
- factions
summary: List Factions
operationId: list_factions_v1_factions_get
security:
- HTTPBearer: []
parameters:
- name: campaign_id
in: query
required: true
schema:
type: string
description: Campaign ID to filter factions
title: Campaign Id
description: Campaign ID to filter factions
- name: search
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Search factions by name
title: Search
description: Search factions by name
- name: approved_only
in: query
required: false
schema:
type: boolean
description: Show only approved factions
default: true
title: Approved Only
description: Show only approved factions
- name: with_links
in: query
required: false
schema:
type: boolean
description: Return descriptions with [[wikilinks]] intact
default: false
title: With Links
description: Return descriptions with [[wikilinks]] intact
- name: sort
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Sort order. 'name' sorts case-insensitively by faction name at the database level, applied before pagination. Omitted keeps the default (newest first).
title: Sort
description: Sort order. 'name' sorts case-insensitively by faction name at the database level, applied before pagination. Omitted keeps the default (newest first).
- name: page
in: query
required: false
schema:
type: integer
minimum: 1
default: 1
title: Page
- name: size
in: query
required: false
schema:
type: integer
maximum: 100
minimum: 1
default: 20
title: Size
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/PaginatedResponse'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
post:
tags:
- factions
summary: Create Faction
operationId: create_faction_v1_factions_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/FactionCreate'
responses:
'201':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/FactionRead'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/v1/factions/{faction_id}:
get:
tags:
- factions
summary: Get Faction
operationId: get_faction_v1_factions__faction_id__get
security:
- HTTPBearer: []
parameters:
- name: faction_id
in: path
required: true
schema:
type: string
title: Faction Id
- name: with_links
in: query
required: false
schema:
type: boolean
description: Return description with [[wikilinks]] intact
default: false
title: With Links
description: Return description with [[wikilinks]] intact
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'200':
description: Successful Response
content:
application/json:
schema:
anyOf:
- $ref: '#/components/schemas/FactionRead'
- $ref: '#/components/schemas/FactionReadProduct'
title: Response Get Faction V1 Factions Faction Id Get
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
patch:
tags:
- factions
summary: Patch Faction
description: Partially update a faction.
operationId: patch_faction_v1_factions__faction_id__patch
security:
- HTTPBearer: []
parameters:
- name: faction_id
in: path
required: true
schema:
type: string
title: Faction Id
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/FactionUpdate'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/FactionRead'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
delete:
tags:
- factions
summary: Delete Faction
operationId: delete_faction_v1_factions__faction_id__delete
security:
- HTTPBearer: []
parameters:
- name: faction_id
in: path
required: true
schema:
type: string
title: Faction Id
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
responses:
'204':
description: Successful Response
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/v1/factions/links/maintenance:
post:
tags:
- factions
summary: Trigger Faction Links Maintenance
operationId: trigger_faction_links_maintenance_v1_factions_links_maintenance_post
security:
- HTTPBearer: []
parameters:
- name: x-api-key
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: X-Api-Key
- name: authorization
in: header
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Authorization
requestBody:
required: true
content:
application/json:
schema:
anyOf:
- $ref: '#/components/schemas/LinkMaintenanceRequest'
- $ref: '#/components/schemas/LinkMaintenanceUpdateRequest'
title: Maintenance
responses:
'202':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/LinkMaintenanceResult'
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
FactionUpdate:
properties:
name:
anyOf:
- type: string
maxLength: 255
minLength: 1
- type: 'null'
title: Name
aliases:
anyOf:
- items:
type: string
type: array
- type: 'null'
title: Aliases
type:
anyOf:
- type: string
maxLength: 100
- type: 'null'
title: Type
description:
anyOf:
- type: string
maxLength: 10000
- type: 'null'
title: Description
image:
anyOf:
- type: string
maxLength: 2048
- type: 'null'
title: Image
tcg_image:
anyOf:
- type: string
- type: 'null'
title: Tcg Image
type: object
title: FactionUpdate
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
LinkMaintenanceUpdateRequest:
properties:
operation:
type: string
const: update
title: Operation
worldId:
type: string
title: Worldid
targetId:
type: string
title: Targetid
alias:
anyOf:
- type: string
maxLength: 255
minLength: 1
- type: 'null'
title: Alias
newTargetId:
anyOf:
- type: string
- type: 'null'
title: Newtargetid
newAlias:
anyOf:
- type: string
- type: 'null'
title: Newalias
type: object
required:
- operation
- worldId
- targetId
title: LinkMaintenanceUpdateRequest
description: Schema for updating existing links across a campaign.
LinkMaintenanceRequest:
properties:
operation:
type: string
enum:
- add
- remove
title: Operation
worldId:
type: string
title: Worldid
targetId:
type: string
title: Targetid
targetType:
type: string
enum:
- Character
- Faction
- Location
- Item
- Moment
title: Targettype
alias:
type: string
maxLength: 255
minLength: 1
title: Alias
type: object
required:
- operation
- worldId
- targetId
- targetType
- alias
title: LinkMaintenanceRequest
description: Schema for triggering campaign-wide wikilink maintenance via webhook.
FactionRead:
properties:
created_at:
type: string
format: date-time
title: Created At
updated_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Updated At
id:
type: string
title: Id
name:
type: string
title: Name
aliases:
items:
type: string
type: array
title: Aliases
type:
anyOf:
- type: string
- type: 'null'
title: Type
description:
anyOf:
- type: string
- type: 'null'
title: Description
image:
anyOf:
- type: string
- type: 'null'
title: Image
tcg_image:
anyOf:
- type: string
- type: 'null'
title: Tcg Image
campaign_id:
type: string
title: Campaign Id
merge:
type: boolean
title: Merge
default: false
type: object
required:
- created_at
- id
- name
- campaign_id
title: FactionRead
description: 'Read view of a stored faction.
The constrained fields from FactionBase are redeclared here without their
limits on purpose. FactionBase exists to validate *incoming* writes, but
FactionRead validates rows that already exist, and those rows are also
written by the Next.js app straight through Prisma, which enforces none of
these limits. Inheriting them made pydantic reject legacy rows on read, so
`GET /v1/factions/{id}` answered 500 for every faction whose stored
description was longer than the create/update cap. `CharacterRead` has
always relaxed its own text fields for this reason; these types had not.'
PaginatedResponse:
properties:
data:
items: {}
type: array
title: Data
total:
type: integer
title: Total
page:
type: integer
title: Page
size:
type: integer
title: Size
pages:
type: integer
title: Pages
type: object
required:
- data
- total
- page
- size
- pages
title: PaginatedResponse
FactionReadProduct:
properties:
created_at:
type: string
format: date-time
title: Created At
updated_at:
anyOf:
- type: string
format: date-time
- type: 'null'
title: Updated At
id:
type: string
title: Id
name:
type: string
title: Name
aliases:
items:
type: string
type: array
title: Aliases
type:
anyOf:
- type: string
- type: 'null'
title: Type
description:
anyOf:
- type: string
- type: 'null'
title: Description
image:
anyOf:
- type: string
- type: 'null'
title: Image
tcg_image:
anyOf:
- type: string
- type: 'null'
title: Tcg Image
campaign_id:
type: string
title: Campaign Id
merge:
type: boolean
title: Merge
default: false
approved:
type: boolean
title: Approved
default: false
pending:
type: boolean
title: Pending
default: false
tag_count:
type: integer
title: Tag Count
default: 0
type: object
required:
- created_at
- id
- name
- campaign_id
title: FactionReadProduct
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
input:
title: Input
ctx:
type: object
title: Context
type: object
required:
- loc
- msg
- type
title: ValidationError
LinkMaintenanceResult:
properties:
success:
type: boolean
title: Success
taskId:
anyOf:
- type: string
- type: 'null'
title: Taskid
type: object
required:
- success
title: LinkMaintenanceResult
FactionCreate:
properties:
name:
type: string
maxLength: 255
minLength: 1
title: Name
aliases:
items:
type: string
type: array
title: Aliases
type:
anyOf:
- type: string
maxLength: 100
- type: 'null'
title: Type
description:
anyOf:
- type: string
maxLength: 10000
- type: 'null'
title: Description
image:
anyOf:
- type: string
maxLength: 2048
- type: 'null'
title: Image
tcg_image:
anyOf:
- type: string
- type: 'null'
title: Tcg Image
campaign_id:
type: string
title: Campaign Id
type: object
required:
- name
- campaign_id
title: FactionCreate
securitySchemes:
HTTPBearer:
type: http
scheme: bearer