Zum Hauptinhalt springen

Entwickler

REST-API-Dokumentation

Eine JSON-über-HTTPS-API für die juristische KI von Attorly. Sie führt dieselben Operationen aus wie der MCP-Server, mit denselben Schlüsseln, Scopes, Limits und derselben Abrechnung.

Schnellstart

Einen Vertrag hochladen und in vier Schritten analysieren.

  1. 1. Schlüssel erstellen

    Erstellen Sie unter Einstellungen › Entwickler einen Schlüssel und wählen Sie REST API. Derselbe Schlüssel funktioniert für den MCP-Server. Speichern Sie ihn in einer Umgebungsvariablen:

    bash
    export ATTORLY_API_KEY=lbmcp_your_api_key
  2. 2. Ein Dokument hochladen

    Senden Sie die Datei als multipart/form-data. data.id in der Antwort ist die ID des Dokuments. analyze=false speichert es, ohne die Hintergrundanalyse zu starten, weil der nächste Schritt eine ausführt.

    bash
    curl -X POST https://attorly.ai/api/v1/documents \
      -H "Authorization: Bearer $ATTORLY_API_KEY" \
      -H "Idempotency-Key: $(uuidgen)" \
      -F "[email protected]" \
      -F "type=NDA" \
      -F "analyze=false"
  3. 3. Analysieren

    Prefer: wait=30 wartet bis zu 30 Sekunden auf das Ergebnis. Eine fertige Analyse kommt als 200 mit dem Ergebnis in data zurück. Dauert sie länger, erhalten Sie 202 Accepted mit einem Location-Header, der auf die Operation zeigt.

    bash
    curl -i -X POST https://attorly.ai/api/v1/documents/$DOCUMENT_ID/analyses \
      -H "Authorization: Bearer $ATTORLY_API_KEY" \
      -H "Idempotency-Key: $(uuidgen)" \
      -H "Prefer: wait=30" \
      -H "Content-Type: application/json" \
      -d '{ "mode": "full", "options": { "partyRole": "BUYER" } }'
  4. 4. Das Ergebnis abholen

    Rufen Sie die Operation ab, bis ihr Status succeeded oder failed ist. Die Analyse steht in result. Retry-After gibt an, wie viele Sekunden Sie zwischen den Abrufen warten sollten.

    bash
    curl https://attorly.ai/api/v1/operations/$OPERATION_ID \
      -H "Authorization: Bearer $ATTORLY_API_KEY"

Authentifizierung

Senden Sie die Zugangsdaten im Authorization-Header als Bearer-Token. Schlüssel aus Einstellungen › Entwickler beginnen mit lbmcp_ und funktionieren in Pro und Enterprise, für die REST-API und den MCP-Server gleichermaßen. Organisationsschlüssel in Enterprise beginnen mit atly_ (atly_rk_ für eingeschränkte Schlüssel, atly_test_ für den Testmodus); ältere lb_-Schlüssel funktionieren weiterhin. Apps, die im Namen einer Person handeln, verwenden OAuth.

http
Authorization: Bearer atly_live_…   # or lbmcp_…, atly_test_…, an OAuth access token

Berechtigungen (Scopes)

Jeder Endpunkt benötigt die daneben aufgeführten Berechtigungen. Ein Schlüssel ohne sie erhält 403 insufficient_scope, und requiredScopes im Fehler listet alle Berechtigungen auf, die der Aufruf braucht. API-Schlüssel der Organisation und OAuth verwenden diese Namen:

BerechtigungScope des Organisations-API-Schlüssels
DOCUMENTS_READdocuments:read
DOCUMENTS_WRITEdocuments:write
DOCUMENTS_DELETEdocuments:delete
DOCUMENTS_ANALYZEanalysis:create
CLAUSES_READclauses:read
RESEARCH_READresearch:read
REDLINES_GENERATEredlines:write
NEGOTIATIONS_READnegotiations:read
WORKFLOWS_EXECUTEworkflows:execute
DUE_DILIGENCE_FULLdue-diligence:write
TEMPLATES_READtemplates:read
TEMPLATES_DRAFTdrafts:write
CASES_READcases:read
CASES_WRITEcases:write

Fehler

Jeder Fehler hat dieselbe Form: einen festen Code zum Verzweigen, eine Nachricht für Menschen und eine requestId für den Support.

http
HTTP/1.1 403 Forbidden
Content-Type: application/json
Request-Id: req_7Hq2LmN4pX9sT1vB3cD5eF6g
Attorly-Version: 2026-12-01

{
  "error": {
    "type": "permission_error",
    "code": "insufficient_scope",
    "message": "Insufficient permissions. Missing scope: redlines:write.",
    "requiredScopes": ["redlines:write"],
    "docUrl": "https://attorly.ai/docs/api/errors#insufficient_scope",
    "requestId": "req_7Hq2LmN4pX9sT1vB3cD5eF6g"
  }
}

Jeder Code ist mit dem, was zu tun ist, erklärt auf der Seite mit den Fehlercodes

Versionen

Die API ist nach Datum versioniert. Senden Sie Attorly-Version, um die Version für eine Anfrage zu wählen; ohne den Header gilt die Version, mit der der Schlüssel erstellt wurde (Schlüssel aus der Zeit vor der Versionierung nutzen 2026-10-01). Jede Antwort nennt die Version, die geantwortet hat. Inkompatible Änderungen kommen nur mit einer neuen Version, und das Änderungsprotokoll führt sie auf.

http
curl https://attorly.ai/api/v1/documents \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Attorly-Version: 2026-12-01"

HTTP/1.1 200 OK
Attorly-Version: 2026-12-01
Request-Id: req_…

Idempotenz

Senden Sie bei POST-, PATCH- und DELETE-Anfragen einen Idempotency-Key-Header, zum Beispiel eine UUID. Eine Wiederholung mit demselben Schlüssel und derselben Anfrage erhält die erste Antwort mit Idempotent-Replayed: true zurück; die Arbeit wird weder erneut ausgeführt noch erneut abgerechnet. Ein Schlüssel, der für eine andere Anfrage wiederverwendet wird, erhält 422 idempotency_key_reused, einer, der noch läuft, 409 oder – bei einem lang laufenden Aufruf – dieselbe Operation. Serverfehler werden nicht gespeichert, ihre Wiederholung läuft also neu. Schlüssel werden 24 Stunden aufbewahrt.

bash
curl -X POST https://attorly.ai/api/v1/redlines \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $IDEMPOTENCY_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "documentId": "doc_123", "partyRole": "BUYER" }'

# IDEMPOTENCY_KEY=$(uuidgen) once per logical request; a retry with the same key and body:
HTTP/1.1 202 Accepted
Idempotent-Replayed: true

Lang laufende Anfragen

Ab Version 2026-11-01 antworten vollständige Analysen, Redlines, Verhandlungsleitfäden, Workflows, Due-Diligence-Berichte und KI-Entwürfe sofort mit 202 Accepted und einer Operation. Senden Sie Prefer: wait=30, um zuerst bis zu 30 Sekunden (höchstens 60) auf das Ergebnis zu warten, oder Prefer: respond-async, um bei jedem Schreibaufruf 202 zu erhalten. Fragen Sie die Location ab, bis der Status succeeded oder failed ist, oder abonnieren Sie operation.succeeded. Ergebnisse werden 24 Stunden aufbewahrt. Pro Organisation laufen höchstens 5 lang laufende KI-Operationen gleichzeitig; weitere erhalten 429 concurrency_limit_exceeded.

http
HTTP/1.1 202 Accepted
Location: /api/v1/operations/op_abc123
Retry-After: 2

{ "data": { "id": "op_abc123", "object": "operation", "status": "running", "resultUrl": "/api/v1/operations/op_abc123", … } }

Paginierung

Listen liefern { object: "list", data, hasMore, nextCursor } und akzeptieren limit (1 bis 100, Standard 20) und cursor. Senden Sie nextCursor als cursor, um die nächste Seite zu laden. Auf der letzten Seite ist nextCursor null. Ein Cursor bleibt gültig, auch wenn neue Einträge hinzukommen.

http
GET /api/v1/documents?limit=2

{
  "object": "list",
  "data": [ { "id": "doc_2", … }, { "id": "doc_1", … } ],
  "hasMore": true,
  "nextCursor": "eyJ0IjoiMjAyNi0xMC0xMVQxMDowMDowMC4wMDBaIiwiaWQiOiJkb2NfMSJ9"
}

GET /api/v1/documents?limit=2&cursor=eyJ0IjoiMjAy…

Anfragelimits

Eine Anfrage zählt gegen mehrere Fenster: das Stundenlimit des Schlüssels, 300 pro Minute und Person, 600 pro Minute und Organisation, ein Minutenlimit pro Schlüssel für Lese-, Schreib- und KI-Aufrufe sowie das eigene Limit jeder Operation. REST und MCP teilen sich dieselben Zähler. Die Header RateLimit-Policy und RateLimit zeigen alle Fenster; X-RateLimit-* zeigt das, das am ehesten ausgeschöpft ist. Über einem Limit erhalten Sie 429 mit Retry-After.

http
RateLimit-Policy: "key-hour";q=1000;w=3600, "user-minute";q=300;w=60, "org-minute";q=600;w=60, "ai-minute";q=30;w=60, "tool";q=10;w=60
RateLimit: "key-hour";r=998;t=3412, "user-minute";r=297;t=41, "org-minute";r=590;t=41, "ai-minute";r=29;t=41, "tool";r=9;t=41
X-RateLimit-Limit: 10
X-RateLimit-Remaining: 9
X-RateLimit-Reset: 1791720000

Webhooks

Legen Sie mit POST /api/v1/webhook-endpoints einen Endpunkt an, um benachrichtigt zu werden, wenn Arbeit fertig ist, statt abzufragen. Attorly sendet einen POST mit einem JSON-Ereignis und signiert ihn nach Standard Webhooks mit dem whsec_-Geheimnis des Endpunkts. Prüfen Sie die Signatur, bevor Sie dem Inhalt vertrauen, antworten Sie innerhalb von 15 Sekunden mit 2xx und entfernen Sie Duplikate anhand von webhook-id: Fehlgeschlagene Zustellungen werden 72 Stunden lang wiederholt. Sie können das Geheimnis erneuern, ein Testereignis senden und jede Zustellung einsehen.

typescript
import crypto from 'node:crypto';

// Standard Webhooks: verify before you parse. secret is the endpoint's whsec_… value.
export function verifyAttorlyWebhook(rawBody: string, headers: Headers, secret: string): unknown {
  const id = headers.get('webhook-id');
  const timestamp = headers.get('webhook-timestamp');
  const signatures = headers.get('webhook-signature') ?? '';
  if (!id || !timestamp) throw new Error('Missing webhook headers');
  if (Math.abs(Date.now() / 1000 - Number(timestamp)) > 300) throw new Error('Timestamp too old');

  const key = Buffer.from(secret.replace(/^whsec_/, ''), 'base64');
  const expected = crypto.createHmac('sha256', key).update(`${id}.${timestamp}.${rawBody}`).digest();
  const valid = signatures.split(' ').some((entry) => {
    const [version, value] = entry.split(',');
    const given = Buffer.from(value ?? '', 'base64');
    return version === 'v1' && given.length === expected.length && crypto.timingSafeEqual(given, expected);
  });
  if (!valid) throw new Error('Invalid signature');
  return JSON.parse(rawBody); // Deduplicate on webhook-id: a delivery can arrive more than once.
}

Testmodus

Testschlüssel (atly_test_…) erreichen jeden Endpunkt, arbeiten aber mit getrennten Testdaten und liefern feste Beispielergebnisse: Es läuft keine KI und es wird kein Guthaben verbraucht. Ein Testschlüssel sieht nie echte Daten. Tragen Sie einen magischen Wert wie __fail_credits__, __fail_consent__ oder __slow__ in ein beliebiges Textfeld ein, um diesen Fehler oder diese Verzögerung auszulösen. DELETE /api/v1/test-data löscht alles, was Testschlüssel angelegt haben.

bash
curl -X POST https://attorly.ai/api/v1/analyses \
  -H "Authorization: Bearer atly_test_…" \
  -H "Content-Type: application/json" \
  -d '{ "mode": "quick", "content": "__fail_credits__" }'

HTTP/1.1 402 Payment Required
{ "error": { "code": "insufficient_credits", "message": "Test mode: the AI credits are used up …" } }

OAuth

Apps, die im Namen eines Attorly-Nutzers handeln, melden sich mit OAuth 2.1 an: Discovery unter /.well-known/oauth-authorization-server, dynamische Client-Registrierung und der Authorization-Code-Flow mit PKCE (S256). Fordern Sie resource=https://attorly.ai/api/v1 an, um ein Token für die REST-API zu erhalten; ein für den MCP-Server ausgestelltes Token wird hier abgelehnt. Fügen Sie offline_access hinzu, um ein Refresh-Token zu erhalten. Die Person wählt die Organisation und kann die Berechtigungen auf der Zustimmungsseite einschränken.

http
GET https://attorly.ai/.well-known/oauth-protected-resource/api/v1
GET https://attorly.ai/.well-known/oauth-authorization-server

GET https://attorly.ai/api/oauth/authorize?response_type=code&client_id=…&redirect_uri=…
    &code_challenge=…&code_challenge_method=S256&scope=documents:read%20offline_access
    &resource=https://attorly.ai/api/v1&state=…

POST https://attorly.ai/api/oauth/token
grant_type=authorization_code&code=…&code_verifier=…&redirect_uri=…&client_id=…&resource=https://attorly.ai/api/v1

Abrechnung

Operationen mit KI verbrauchen dasselbe KI-Guthaben wie die Attorly-App, aus dem Guthaben des Schlüsselinhabers oder seiner Organisation – egal ob Sie sie über REST oder MCP aufrufen. Ist das Guthaben aufgebraucht, erhalten Sie 402 insufficient_credits. Aufrufe im Testmodus sind kostenlos.

Tarife

Die API ist in Pro und Enterprise enthalten. Wenn der Tarif des Schlüsselinhabers keinen API-Zugang mehr umfasst oder der Inhaber die Organisation verlassen hat, werden Anfragen mit 403 abgelehnt.

Referenz

Jede Operation, generiert aus dem OpenAPI-Dokument, das die API selbst bereitstellt. Pfade sind relativ zu https://attorly.ai. Erfolgreiche Antworten verpacken das Ergebnis in data. Die Feldbeschreibungen sind auf Englisch.

Dokumente

GET/api/v1/documentslistDocuments

Die gespeicherten Dokumente auflisten, die der Schlüssel lesen kann, neueste zuerst.

Berechtigung:DOCUMENTS_READ
Abfrageparameter
FeldTypBeschreibung
type"EMPLOYMENT_CONTRACT" | "LEASE_AGREEMENT" | "PURCHASE_AGREEMENT" | "NDA" | "TERMS_OF_SERVICE" | "EMAIL" | …Only documents of this kind
status"PENDING" | "PROCESSING" | "ANALYZED" | "FAILED"Only documents in this processing state
querystringOnly documents whose name contains this text
includeArchivedbooleanAlso list archived documents (left out by default)
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/documents?limit=20" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/documentsuploadDocument

Ein Dokument als multipart/form-data hochladen oder als JSON mit Base64-Inhalt oder reinem Text. Es wird im Hintergrund analysiert, außer analyze ist false.

Berechtigung:DOCUMENTS_WRITEVerbraucht KI-GuthabenAkzeptiert Datei-Uploads
Anfrageinhalt
FeldTypBeschreibung
filenameerforderlichstringThe file name with its extension, e.g. "nda.pdf"; the extension decides the file type when mimeType is absent
contentBase64stringThe file, base64-encoded
textstringPlain text to store as a .txt document, instead of contentBase64
mimeTypestringThe file's MIME type; checked against its content
namestringDisplay name; defaults to the file name
type"EMPLOYMENT_CONTRACT" | "LEASE_AGREEMENT" | "PURCHASE_AGREEMENT" | "NDA" | "TERMS_OF_SERVICE" | "EMAIL" | …What the document is
urlstring (uri)An https URL Attorly downloads the file from (public hosts only, up to 10 MB), instead of contentBase64 or text
analyzebooleanAnalyse the document in the background after upload, as the app does (uses AI credits). false stores it only
Antwortdaten (201)
FeldTypBeschreibung
iderforderlichstring
nameerforderlichstring
originalNameerforderlichstring
typeerforderlich"EMPLOYMENT_CONTRACT" | "LEASE_AGREEMENT" | "PURCHASE_AGREEMENT" | "NDA" | "TERMS_OF_SERVICE" | "EMAIL" | …
sizeerforderlichinteger
statuserforderlich"PENDING" | "PROCESSING" | "ANALYZED" | "FAILED"PENDING until processing starts; ANALYZED once the analysis is stored
analysisQueuederforderlichbooleantrue when the background analysis was started
createdAterforderlichstringISO 8601 date-time
urlerforderlichstringWhere the document opens in Attorly
curl
curl -X POST "https://attorly.ai/api/v1/documents" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "filename": "nda.txt",
  "text": "This Mutual Non-Disclosure Agreement is entered into by…",
  "type": "NDA"
}'
GET/api/v1/documents/searchsearchDocuments

Den Text der Dokumente durchsuchen, die der Schlüssel lesen darf – nach Bedeutung und nach exakten Wörtern.

Berechtigung:DOCUMENTS_READ
Abfrageparameter
FeldTypBeschreibung
queryerforderlichstringWhat to look for, in plain language or exact words
type"EMPLOYMENT_CONTRACT" | "LEASE_AGREEMENT" | "PURCHASE_AGREEMENT" | "NDA" | "TERMS_OF_SERVICE" | "EMAIL" | …Only documents of this kind
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/documents/search?query=limitation+of+liability&limit=10" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/documents/{documentId}getDocument

Ein Dokument, seinen Verarbeitungsstatus und seine neueste Analyse abrufen.

Berechtigung:DOCUMENTS_READ
Pfadparameter
FeldTypBeschreibung
documentIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstring
nameerforderlichstring
originalNameerforderlichstring
typeerforderlich"EMPLOYMENT_CONTRACT" | "LEASE_AGREEMENT" | "PURCHASE_AGREEMENT" | "NDA" | "TERMS_OF_SERVICE" | "EMAIL" | …
mimeTypeerforderlichstring
sizeerforderlichinteger
statuserforderlich"PENDING" | "PROCESSING" | "ANALYZED" | "FAILED"PENDING until processing starts; ANALYZED once the analysis is stored
archivederforderlichboolean
ownedByYouerforderlichboolean
versionNumbererforderlichinteger | nullThe document's number among its versions you can read ("version 2" — a new version is saved as a new document, never in place); null when it has no other version. documents_list returns the newest version of each document only.
createdAterforderlichstringISO 8601 date-time
updatedAterforderlichstringISO 8601 date-time
fileAvailableerforderlichbooleanfalse when the stored file can no longer be read
governingLawRequirederforderlichbooleantrue when the analysis is held until a governing law is chosen for the document in Attorly
latestAnalysiserforderlichobject | null
urlerforderlichstringWhere the document opens in Attorly
curl
curl "https://attorly.ai/api/v1/documents/doc_abc123" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
DELETE/api/v1/documents/{documentId}deleteDocument

Die Löschung eines Dokuments anfragen, das Ihnen gehört. Das Dokument wird erst gelöscht, wenn Sie die Löschung in Attorly genehmigen.

Berechtigung:DOCUMENTS_DELETE
Pfadparameter
FeldTypBeschreibung
documentIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstring
deletederforderlichbooleantrue only when the document is gone
statuserforderlich"deleted" | "declined" | "awaiting_approval"deleted: the owner approved and it is gone; declined: the owner said no in their app, nothing was deleted; awaiting_approval: it is marked and waits for the owner to delete or keep it in Attorly
requestedAtstringWhen the deletion was first asked for (awaiting_approval)
urlstringWhere the owner approves or keeps the document in Attorly (awaiting_approval)
curl
curl -X DELETE "https://attorly.ai/api/v1/documents/doc_abc123" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
POST/api/v1/analysescreateAnalysis

Ein Dokument oder mitgesendeten Text analysieren. mode ist full (gespeichertes Dokument) oder quick.

Berechtigung:DOCUMENTS_ANALYZEDOCUMENTS_READVerbraucht KI-Guthaben

Das Feld mode im Inhalt wählt eine Variante: mode: full, mode: quick.

Anfrageinhalt
FeldTypBeschreibung
mode"full" | "quick"Runs documents_analyze.
documentIdstring
contentstring
mimeTypestring
optionsobject
curl
curl -X POST "https://attorly.ai/api/v1/analyses" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "mode": "quick",
  "content": "This Agreement is entered into by and between…"
}'
GET/api/v1/documents/{documentId}/analyseslistDocumentAnalyses

Die gespeicherten Analysen eines Dokuments auflisten, neueste zuerst.

Berechtigung:DOCUMENTS_READ
Pfadparameter
FeldTypBeschreibung
documentIderforderlichstring
Abfrageparameter
FeldTypBeschreibung
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/documents/doc_abc123/analyses" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/documents/{documentId}/analysescreateDocumentAnalysis

Ein gespeichertes Dokument analysieren.

Berechtigung:DOCUMENTS_ANALYZEDOCUMENTS_READVerbraucht KI-Guthaben
Pfadparameter
FeldTypBeschreibung
documentIderforderlichstring

Das Feld mode im Inhalt wählt eine Variante: mode: full, mode: quick.

Anfrageinhalt
FeldTypBeschreibung
mode"full" | "quick"Runs documents_analyze.
contentstring
mimeTypestring
optionsobject
curl
curl -X POST "https://attorly.ai/api/v1/documents/doc_abc123/analyses" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "mode": "full",
  "options": {
    "partyRole": "BUYER"
  }
}'
GET/api/v1/documents/{documentId}/textgetDocumentText

Den reinen Text eines gespeicherten PDF- oder DOCX-Dokuments extrahieren.

Berechtigung:DOCUMENTS_READ
Pfadparameter
FeldTypBeschreibung
documentIderforderlichstring
Abfrageparameter
FeldTypBeschreibung
offsetintegerCharacter offset to start from; pass the nextOffset of the previous call to read on
maxCharactersintegerMost characters to return in this call
Antwortdaten (200)
FeldTypBeschreibung
texterforderlichstringThe document text from offset (untrusted content)
documentNameerforderlichstring
documentTypeerforderlichstring
mimeTypeerforderlichstring | null
characterCounterforderlichintegerCharacters in the whole document
wordCounterforderlichintegerWords in the whole document
offseterforderlichinteger
nextOffseterforderlichinteger | nullPass as offset to read on; null when the text ends here
truncatederforderlichbooleantrue when the text continues past this slice
curl
curl "https://attorly.ai/api/v1/documents/doc_abc123/text" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/analyses/{analysisId}getAnalysis

Eine gespeicherte Analyse abrufen: Zusammenfassung, Risiko, wichtige Bedingungen, Klauseln und Empfehlungen.

Berechtigung:DOCUMENTS_READ
Pfadparameter
FeldTypBeschreibung
analysisIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstring
documentIderforderlichstring
documentNameerforderlichstring
summaryerforderlichstring | null
riskLevelerforderlich"LOW" | "MEDIUM" | "HIGH" | "CRITICAL"
riskScoreerforderlichnumber
keyTermserforderlicharray of any
clauseserforderlicharray of any
recommendationserforderlicharray of any
modeerforderlichstringSINGLE or CONSENSUS
createdAterforderlichstringISO 8601 date-time
urlerforderlichstring
curl
curl "https://attorly.ai/api/v1/analyses/your_analysisId" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/comparisonscreateComparison

Zwei Dokumente oder Texte Zeile für Zeile vergleichen.

Berechtigung:DOCUMENTS_READ
Anfrageinhalt
FeldTypBeschreibung
sourceDocumentIdstring
sourceContentstring
targetDocumentIdstring
targetContentstring
Antwortdaten (200)
FeldTypBeschreibung
differenceserforderlicharray of object
summaryerforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/comparisons" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "sourceDocumentId": "doc_abc123",
  "targetDocumentId": "doc_def456"
}'

Klauseln

GET/api/v1/clausessearchClauses

Die Klauselbibliothek durchsuchen.

Berechtigung:CLAUSES_READ
Abfrageparameter
FeldTypBeschreibung
queryerforderlichstring
category"INDEMNIFICATION" | "LIABILITY" | "TERMINATION" | "CONFIDENTIALITY" | "INTELLECTUAL_PROPERTY" | "PAYMENT" | …
jurisdictionstring
riskLevel"LOW" | "MEDIUM" | "HIGH" | "CRITICAL"
limitinteger
Antwortdaten (200)
FeldTypBeschreibung
clauseserforderlicharray of object
counterforderlichinteger
curl
curl "https://attorly.ai/api/v1/clauses?query=limitation+of+liability&limit=5" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/clauses/risk-assessmentscreateClauseRiskAssessment

Das Risiko einer Klausel bewerten.

Berechtigung:CLAUSES_READ
Anfrageinhalt
FeldTypBeschreibung
clauseTexterforderlichstring
category"INDEMNIFICATION" | "LIABILITY" | "TERMINATION" | "CONFIDENTIALITY" | "INTELLECTUAL_PROPERTY" | "PAYMENT" | …The kind of clause; its risk rules are applied
jurisdictionstringISO 3166-1 alpha-2 country code; defaults to international
contractTypestring
partyRole"BUYER" | "SELLER" | "LANDLORD" | "TENANT" | "EMPLOYER" | "EMPLOYEE" | …
Antwortdaten (200)
FeldTypBeschreibung
clauseTextstring
clauseTypeerforderlichstring
jurisdictionerforderlichstring
overallRiskScoreerforderlichnumber
riskLevelerforderlich"LOW" | "MEDIUM" | "HIGH" | "CRITICAL"
riskFactorserforderlicharray of object
recommendationserforderlicharray of string
alternativesarray of object
complianceIssuesarray of object
negotiationTipsarray of string
curl
curl -X POST "https://attorly.ai/api/v1/clauses/risk-assessments" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "clauseText": "The Supplier’s total liability shall not exceed the fees paid in the preceding month.",
  "category": "LIABILITY",
  "partyRole": "BUYER"
}'
POST/api/v1/clauses/market-comparisonscreateClauseMarketComparison

Eine Klausel mit marktüblichen Formulierungen vergleichen.

Berechtigung:CLAUSES_READ
Anfrageinhalt
FeldTypBeschreibung
clauseTexterforderlichstring
categoryerforderlich"INDEMNIFICATION" | "LIABILITY" | "TERMINATION" | "CONFIDENTIALITY" | "INTELLECTUAL_PROPERTY" | "PAYMENT" | …
contractTypestring
jurisdictionstring
Antwortdaten (200)
FeldTypBeschreibung
inputClauseerforderlichstring
categoryerforderlichstring
marketStandardserforderlicharray of object
comparisonerforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/clauses/market-comparisons" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "clauseText": "Either party may terminate this Agreement on 10 days’ written notice.",
  "category": "TERMINATION"
}'
POST/api/v1/clauses/playbook-checkscreateClausePlaybookCheck

Eine Klausel anhand eines Playbooks prüfen.

Berechtigung:CLAUSES_READ
Anfrageinhalt
FeldTypBeschreibung
clauseTexterforderlichstring
playbookIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
playbookNameerforderlichstring
complianterforderlichboolean
violationserforderlicharray of string
warningserforderlicharray of string
rulesCheckederforderlichinteger
curl
curl -X POST "https://attorly.ai/api/v1/clauses/playbook-checks" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "clauseText": "This Agreement is governed by the laws of England.",
  "playbookId": "pb_abc123"
}'

Recherche

POST/api/v1/research/searchessearchResearch

Rechtsquellen wie Lovdata, EUR-Lex und CourtListener durchsuchen.

Berechtigung:RESEARCH_READVerbraucht KI-Guthaben
Anfrageinhalt
FeldTypBeschreibung
queryerforderlichstring
jurisdictionsarray of stringISO 3166-1 alpha-2 country code to search under, or "EU"; the first entry is used. Defaults to the key owner's country.
sourcesarray of "lovdata" | "eurlex" | "legislation_uk" | "congress_gov" | "courtlistener" | "finlex"Keep only results from these publishers
dateFromstringKeep only dated results on or after this day
dateTostringKeep only dated results on or before this day
limitinteger
Antwortdaten (200)
FeldTypBeschreibung
queryerforderlichstring
jurisdictionerforderlichstring
resultserforderlicharray of object
totalCounterforderlichintegerResults matching the filters, before limit
sourcesstring
curl
curl -X POST "https://attorly.ai/api/v1/research/searches" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "query": "notice period for terminating a commercial lease",
  "jurisdictions": [
    "NO"
  ],
  "limit": 5
}'
GET/api/v1/research/statutesgetStatute

Ein Gesetz anhand der Fundstelle abrufen.

Berechtigung:RESEARCH_READVerbraucht KI-Guthaben
Abfrageparameter
FeldTypBeschreibung
citationerforderlichstring
jurisdictionerforderlichstringISO 3166-1 alpha-2 country code, or "EU"
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstring
titleerforderlichstring
sourceerforderlichstring
jurisdictionstring
citationstring
urlstring
datestring
excerptstring
relevanceScorenumber
attributionstring
asOfstring
consolidatedAsOfstringISO date the stored text is "as amended through", as its publisher states
inForceTostringISO date the act stops/stopped being in force, when the publisher states one
repealedAtstringISO date the act was repealed, when it was
lawDatesReadbooleanTrue when the publisher's dates were read for the act; a missing consolidatedAsOf then means an unamended text
curl
curl "https://attorly.ai/api/v1/research/statutes?citation=LOV-1999-03-26-17&jurisdiction=NO" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"

Änderungsvorschläge

POST/api/v1/redlinescreateRedlines

Änderungsvorschläge für ein Dokument oder einen Text erzeugen.

Berechtigung:REDLINES_GENERATEVerbraucht KI-Guthaben
Anfrageinhalt
FeldTypBeschreibung
documentIdstring
contentstring
partyRoleerforderlich"BUYER" | "SELLER" | "LANDLORD" | "TENANT" | "EMPLOYER" | "EMPLOYEE"
riskTolerance"CONSERVATIVE" | "MODERATE" | "AGGRESSIVE"
focusAreasarray of string
playbookIdstringRedline against this playbook's position ladders (own, organisation, system or shared playbooks)
side"OUR_PAPER" | "THEIR_PAPER" | "EITHER"Whose paper the document is, to pick the playbook positions that apply
Antwortdaten (200)
FeldTypBeschreibung
changeserforderlicharray of object
summaryobject
negotiationNotesarray of string
statisticserforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/redlines" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "documentId": "doc_abc123",
  "partyRole": "BUYER",
  "riskTolerance": "CONSERVATIVE"
}'
POST/api/v1/documents/{documentId}/redlines/resolutionsresolveRedlines

Änderungen an einem Dokument annehmen oder ablehnen.

Berechtigung:REDLINES_GENERATE
Pfadparameter
FeldTypBeschreibung
documentIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
changeserforderlicharray of object
Antwortdaten (200)
FeldTypBeschreibung
acceptederforderlichinteger
rejectederforderlichinteger
messageerforderlichstring
curl
curl -X POST "https://attorly.ai/api/v1/documents/doc_abc123/redlines/resolutions" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "changes": [
    {
      "id": "chg_1",
      "action": "accept"
    },
    {
      "id": "chg_2",
      "action": "reject"
    }
  ]
}'

Verhandlungen

POST/api/v1/negotiations/position-analysescreateNegotiationPositionAnalysis

Eine Verhandlungsposition analysieren.

Berechtigung:NEGOTIATIONS_READVerbraucht KI-Guthaben
Anfrageinhalt
FeldTypBeschreibung
documentIdstring
contentstring
partyRoleerforderlich"BUYER" | "SELLER" | "LANDLORD" | "TENANT" | "EMPLOYER" | "EMPLOYEE"
contextobject
Antwortdaten (200)
FeldTypBeschreibung
overallPositionerforderlichstringFAVORABLE, BALANCED or UNFAVORABLE
positionserforderlicharray of object
prioritizedConcessionsarray of string
dealBreakersarray of string
suggestedApproachstring
estimatedOutcomeobject
curl
curl -X POST "https://attorly.ai/api/v1/negotiations/position-analyses" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "documentId": "doc_abc123",
  "partyRole": "BUYER"
}'
POST/api/v1/negotiations/playbookscreateNegotiationPlaybook

Aus einer Strategie ein Verhandlungs-Playbook erstellen.

Berechtigung:NEGOTIATIONS_READVerbraucht KI-Guthaben
Anfrageinhalt
FeldTypBeschreibung
strategyerforderlichobject
contextobject
Antwortdaten (200)
FeldTypBeschreibung
playbookerforderlicharray of object
anticipatedObjectionserforderlicharray of object
recommendationserforderlicharray of string
summaryerforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/negotiations/playbooks" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "strategy": {
    "overallPosition": "collaborative",
    "priorities": [
      "Cap liability at 12 months of fees",
      "Keep Norwegian law"
    ]
  }
}'

Arbeitsabläufe

GET/api/v1/workflows/templateslistWorkflowTemplates

Workflow-Vorlagen auflisten.

Berechtigung:WORKFLOWS_EXECUTE
Abfrageparameter
FeldTypBeschreibung
category"MA_ACQUISITION" | "MA_MERGER" | "INVESTMENT" | "IPO" | "REAL_ESTATE" | "REGULATORY" | …Due diligence project type the template is built for
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/workflows/templates?limit=20" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/workflows/executionslistWorkflowExecutions

Workflow-Ausführungen auflisten, neueste zuerst, optional für ein Projekt oder einen Status.

Berechtigung:WORKFLOWS_EXECUTE
Abfrageparameter
FeldTypBeschreibung
projectIdstringOnly executions on this due diligence project
status"PENDING" | "RUNNING" | "WAITING_FOR_INPUT" | "WAITING_FOR_APPROVAL" | "PAUSED" | "COMPLETED" | …
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/workflows/executions?status=COMPLETED&limit=20" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/workflows/executionscreateWorkflowExecution

Einen Workflow für ein Due-Diligence-Projekt starten.

Berechtigung:WORKFLOWS_EXECUTEVerbraucht KI-Guthaben
Anfrageinhalt
FeldTypBeschreibung
templateIderforderlichstring
projectIderforderlichstring
inputserforderlichobject
optionsobject
Antwortdaten (202)
FeldTypBeschreibung
executionIderforderlichstring
templateIderforderlichstring
templateNameerforderlichstring
statuserforderlichstring
startedAterforderlichstringISO 8601 date-time
messageerforderlichstring
curl
curl -X POST "https://attorly.ai/api/v1/workflows/executions" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "templateId": "wft_abc123",
  "projectId": "ddp_abc123",
  "inputs": {}
}'
GET/api/v1/workflows/executions/{executionId}getWorkflowExecution

Den Status einer Workflow-Ausführung abrufen.

Berechtigung:WORKFLOWS_EXECUTE
Pfadparameter
FeldTypBeschreibung
executionIderforderlichstring
Abfrageparameter
FeldTypBeschreibung
includeStepsboolean
Antwortdaten (200)
FeldTypBeschreibung
executionIderforderlichstring
templateNameerforderlichstring
statuserforderlichstring
startedAtstringISO 8601 date-time
completedAtstringISO 8601 date-time
variablesobject
errorstring | null
stepsarray of object
curl
curl "https://attorly.ai/api/v1/workflows/executions/wfx_abc123" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"

Due Diligence

GET/api/v1/due-diligence/projectslistDueDiligenceProjects

Due-Diligence-Projekte auflisten, neueste zuerst.

Berechtigung:DUE_DILIGENCE_FULL
Abfrageparameter
FeldTypBeschreibung
status"NOT_STARTED" | "IN_PROGRESS" | "UNDER_REVIEW" | "COMPLETED" | "ON_HOLD" | "CANCELLED"Only projects in this state
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/due-diligence/projects?limit=20" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/due-diligence/projectscreateDueDiligenceProject

Ein Due-Diligence-Projekt anlegen.

Berechtigung:DUE_DILIGENCE_FULL
Anfrageinhalt
FeldTypBeschreibung
nameerforderlichstring
dealTypeerforderlich"MA_ACQUISITION" | "MA_MERGER" | "INVESTMENT" | "IPO" | "REAL_ESTATE" | "REGULATORY" | …
targetCompanystring
descriptionstring
settingsobject
Antwortdaten (201)
FeldTypBeschreibung
projectIderforderlichstring
nameerforderlichstring
projectTypeerforderlichstring
statuserforderlichstring
createdAterforderlichstringISO 8601 date-time
messageerforderlichstring
curl
curl -X POST "https://attorly.ai/api/v1/due-diligence/projects" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "Project Falcon",
  "dealType": "MA_ACQUISITION",
  "targetCompany": "Target AS"
}'
GET/api/v1/due-diligence/projects/{projectId}getDueDiligenceProject

Ein Due-Diligence-Projekt mit der Zahl seiner Dokumente und Befunde abrufen.

Berechtigung:DUE_DILIGENCE_FULL
Pfadparameter
FeldTypBeschreibung
projectIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstring
nameerforderlichstring
descriptionerforderlichstring | null
projectTypeerforderlichstring
statuserforderlichstring
priorityerforderlichstring
targetCompanyerforderlichstring | null
dueDateerforderlichstring | null
documentCounterforderlichinteger
findingCounterforderlichinteger
createdAterforderlichstringISO 8601 date-time
updatedAterforderlichstringISO 8601 date-time
completedAterforderlichstring | null
curl
curl "https://attorly.ai/api/v1/due-diligence/projects/ddp_abc123" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/due-diligence/projects/{projectId}/documentsaddDueDiligenceDocuments

Dokumente zu einem Due-Diligence-Projekt hinzufügen.

Berechtigung:DUE_DILIGENCE_FULL
Pfadparameter
FeldTypBeschreibung
projectIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
documentIdserforderlicharray of string
categorystring
Antwortdaten (200)
FeldTypBeschreibung
projectIderforderlichstring
documentsAddederforderlichinteger
totalDocumentserforderlichinteger
categoryerforderlichstring
messageerforderlichstring
curl
curl -X POST "https://attorly.ai/api/v1/due-diligence/projects/ddp_abc123/documents" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "documentIds": [
    "doc_abc123",
    "doc_def456"
  ]
}'
GET/api/v1/due-diligence/projects/{projectId}/findingslistDueDiligenceFindings

Die Feststellungen eines Due-Diligence-Projekts auflisten.

Berechtigung:DUE_DILIGENCE_FULL
Pfadparameter
FeldTypBeschreibung
projectIderforderlichstring
Abfrageparameter
FeldTypBeschreibung
riskLevel"INFO" | "LOW" | "MEDIUM" | "HIGH" | "CRITICAL"
categorystring
limitinteger
Antwortdaten (200)
FeldTypBeschreibung
projectIderforderlichstring
projectNameerforderlichstring
findingserforderlicharray of object
riskSummaryerforderlichobjectNumber of findings per severity
totalFindingserforderlichinteger
pendingProposalserforderlichintegerRisks the AI proposed that wait for a reviewer: not findings, not listed, not in any report
curl
curl "https://attorly.ai/api/v1/due-diligence/projects/ddp_abc123/findings?riskLevel=HIGH" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/due-diligence/projects/{projectId}/reportscreateDueDiligenceReport

Einen Due-Diligence-Bericht erstellen.

Berechtigung:DUE_DILIGENCE_FULL
Pfadparameter
FeldTypBeschreibung
projectIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
formaterforderlich"pdf" | "markdown""markdown" returns the report text; "pdf" also returns the formatted PDF (base64)
sectionsarray of "executive_summary" | "risk_overview" | "findings_detail" | "document_analysis" | "recommendations"
includeRecommendationsboolean
Antwortdaten (201)
FeldTypBeschreibung
reportIderforderlichstring
projectIderforderlichstring
projectNamestring
formaterforderlich"pdf" | "markdown"
statuserforderlichstring
sectionsarray of string
documentCountinteger
findingCountinteger
pendingProposalsintegerRisks the AI proposed that wait for a reviewer when the report was made: left out of it, and counted at its top
markdownerforderlichstring
attachmentobject
messagestring
curl
curl -X POST "https://attorly.ai/api/v1/due-diligence/projects/ddp_abc123/reports" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "format": "markdown"
}'

Vorlagen und Entwürfe

GET/api/v1/templateslistTemplates

Dokumentvorlagen auflisten.

Berechtigung:TEMPLATES_READ
Abfrageparameter
FeldTypBeschreibung
category"NDA" | "EMPLOYMENT" | "SERVICE_AGREEMENT" | "LEASE" | "REAL_ESTATE" | "CORPORATE" | …
jurisdictionstringISO 3166-1 alpha-2 country code (e.g. "NO", "GB"); jurisdiction-neutral templates are always included
languagestringISO 639-1 language code of the template text (e.g. "en", "nb")
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/templates?limit=20" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/draftscreateDraft

Einen Entwurf aus einer Vorlage (mode template) oder mit KI (mode ai) erstellen.

Berechtigung:TEMPLATES_DRAFTVerbraucht KI-Guthaben

Das Feld mode im Inhalt wählt eine Variante: mode: template, mode: ai.

Anfrageinhalt
FeldTypBeschreibung
mode"template" | "ai"Runs templates_draft.
templateIdstring
variablesobject
optionsobject
documentTypestring
requirementsstring
contextobject
curl
curl -X POST "https://attorly.ai/api/v1/drafts" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "mode": "template",
  "templateId": "tpl_abc123",
  "variables": {
    "partyA": "Acme AS",
    "partyB": "Beta AB"
  }
}'

Fälle

GET/api/v1/caseslistCases

Die eigenen Fälle auflisten, zuletzt geänderte zuerst.

Berechtigung:CASES_READ
Abfrageparameter
FeldTypBeschreibung
status"ACTIVE" | "CLOSED" | "ARCHIVED"Only cases in this state; all states when absent
limitinteger
cursorstringPass the nextCursor of the previous page to get the next one
curl
curl "https://attorly.ai/api/v1/cases?status=ACTIVE&limit=20" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/cases/{caseId}/timelinegetCaseTimeline

Die Zeitleiste eines Falls abrufen: jedes Ereignis mit Datum, Belegen und der Position der Gegenseite.

Berechtigung:CASES_READ
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
caseerforderlichobject
eventserforderlicharray of objectIn date order
counterforderlichinteger
needsReviewCounterforderlichintegerEvents an AI added that no person has confirmed
deletionRequestedCounterforderlichintegerEvents waiting for the owner to approve their deletion
curl
curl "https://attorly.ai/api/v1/cases/case_abc123/timeline" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/cases/{caseId}/timeline/eventscreateTimelineEvent

Ein Ereignis zur Zeitleiste eines Falls hinzufügen.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
titleerforderlichstringWhat happened, in one line (at most 300 characters)
descriptionstring | nullMore detail, or null to clear it
whenerforderlichobjectWhen it happened, as precisely as it is known. precision TIME: start "YYYY-MM-DD" and time "HH:MM" (24-hour, in the case's time zone). DAY: start "YYYY-MM-DD". MONTH: start "YYYY-MM". YEAR: start "YYYY". PERIOD: start and end "YYYY-MM-DD", end after start. approximate: true when the date is an estimate; it is then written "c. …".
category"CONTRACT" | "DEADLINE" | "INCIDENT" | "FILING" | "CORRESPONDENCE" | "COURT_DATE" | …What kind of event it is; OTHER when absent
importantbooleanMarks a key event; exports can be limited to key events
agreement"UNMARKED" | "AGREED" | "DISPUTED"Whether the other side agrees that it happened this way: AGREED, DISPUTED, or UNMARKED (not assessed)
opposingVersionstring | nullThe other side's account of a DISPUTED event. Kept only while agreement is DISPUTED
commentstring | nullThe owner's private note. Exports print it only when asked to
confidentialbooleanLeave this event out whenever the timeline is shared or exported
sourcesarray of objectThe case documents that evidence the event, with an optional page or section ("p. 3"). Each documentId must be a document of this case. On update, the list replaces the event's sources
Antwortdaten (201)
FeldTypBeschreibung
caseIderforderlichstring
eventerforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/cases/case_abc123/timeline/events" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "title": "Landlord gave written notice of termination",
  "when": {
    "precision": "DAY",
    "start": "2026-03-02"
  },
  "category": "CORRESPONDENCE",
  "important": true,
  "agreement": "DISPUTED",
  "opposingVersion": "The landlord says the notice was handed over on 27 February.",
  "sources": [
    {
      "documentId": "doc_abc123",
      "locator": "p. 1"
    }
  ]
}'
PATCH/api/v1/cases/{caseId}/timeline/events/{eventId}updateTimelineEvent

Ein Ereignis in der Zeitleiste eines Falls ändern oder ein von der KI hinzugefügtes bestätigen.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
eventIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
titlestringWhat happened, in one line (at most 300 characters)
descriptionstring | nullMore detail, or null to clear it
whenobjectWhen it happened, as precisely as it is known. precision TIME: start "YYYY-MM-DD" and time "HH:MM" (24-hour, in the case's time zone). DAY: start "YYYY-MM-DD". MONTH: start "YYYY-MM". YEAR: start "YYYY". PERIOD: start and end "YYYY-MM-DD", end after start. approximate: true when the date is an estimate; it is then written "c. …".
category"CONTRACT" | "DEADLINE" | "INCIDENT" | "FILING" | "CORRESPONDENCE" | "COURT_DATE" | …What kind of event it is; OTHER when absent
importantbooleanMarks a key event; exports can be limited to key events
agreement"UNMARKED" | "AGREED" | "DISPUTED"Whether the other side agrees that it happened this way: AGREED, DISPUTED, or UNMARKED (not assessed)
opposingVersionstring | nullThe other side's account of a DISPUTED event. Kept only while agreement is DISPUTED
commentstring | nullThe owner's private note. Exports print it only when asked to
confidentialbooleanLeave this event out whenever the timeline is shared or exported
sourcesarray of objectThe case documents that evidence the event, with an optional page or section ("p. 3"). Each documentId must be a document of this case. On update, the list replaces the event's sources
Antwortdaten (200)
FeldTypBeschreibung
caseIderforderlichstring
eventerforderlichobject
curl
curl -X PATCH "https://attorly.ai/api/v1/cases/case_abc123/timeline/events/your_eventId" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
DELETE/api/v1/cases/{caseId}/timeline/events/{eventId}deleteTimelineEvent

Das Löschen eines Ereignisses aus der Zeitleiste eines Falls anfragen. Das Ereignis wird erst gelöscht, wenn der Inhaber es in Attorly genehmigt.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
eventIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
caseIderforderlichstring
iderforderlichstring
deletederforderlichbooleantrue only when the event is gone
statuserforderlich"deleted" | "declined" | "awaiting_approval"deleted: the owner approved and it is gone; declined: the owner said no in their app, nothing was deleted; awaiting_approval: it is marked and waits for the owner to delete or keep it in Attorly
requestedAtstringWhen the deletion was first asked for (awaiting_approval)
urlstringWhere the owner approves or keeps the event in Attorly (awaiting_approval)
curl
curl -X DELETE "https://attorly.ai/api/v1/cases/case_abc123/timeline/events/your_eventId" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
POST/api/v1/cases/{caseId}/timeline/exportexportCaseTimeline

Die Zeitleiste eines Falls als PDF-, Word-, ODT-, Excel- oder PowerPoint-Datei exportieren.

Berechtigung:CASES_READ
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
layouterforderlich"overview" | "chronology" | "numbered" | "visual"overview: date and what happened, for the other party, a complaints board or a lawyer. chronology: numbered table with sources and an exhibit list, for a court. numbered: one numbered paragraph per event with exhibit references, for the facts section of a filing. visual: the time axis on one landscape page
formaterforderlich"pdf" | "docx" | "odt" | "xlsx" | "pptx"The file type. overview and chronology: pdf, docx, odt, xlsx or pptx. numbered: pdf, docx or odt. visual: pdf or pptx
optionsobject
localestringLanguage of the file's headings, dates and file name, as a locale Attorly ships (e.g. "en", "nb", "de"); the account's language when absent or not offered
Antwortdaten (200)
FeldTypBeschreibung
caseIderforderlichstring
layouterforderlich"overview" | "chronology" | "numbered" | "visual"
formaterforderlich"pdf" | "docx" | "odt" | "xlsx" | "pptx"
localeerforderlichstringThe language the file is written in
eventCounterforderlichintegerEvents in the file
exhibitCounterforderlichintegerDocuments in the exhibit list (chronology and numbered layouts)
leftOutConfidentialerforderlichintegerEvents left out because they are marked confidential
attachmenterforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/cases/case_abc123/timeline/export" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "layout": "chronology",
  "format": "docx",
  "options": {
    "markAgreement": true
  },
  "locale": "en"
}'
GET/api/v1/cases/{caseId}/deadlineslistCaseDeadlines

Die Fristen eines Falls auflisten, die nächste zuerst, mit Angabe, wessen Frist es ist und ob sie erledigt oder überschritten ist.

Berechtigung:CASES_READ
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Abfrageparameter
FeldTypBeschreibung
status"open" | "completed"open: not yet marked done; completed: marked done; both when absent
Antwortdaten (200)
FeldTypBeschreibung
caseerforderlichobject
deadlineserforderlicharray of objectSoonest first
counterforderlichinteger
overdueCounterforderlichinteger
curl
curl "https://attorly.ai/api/v1/cases/case_abc123/deadlines?status=open" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/cases/{caseId}/deadlinescreateCaseDeadline

Eine Frist zu einem Fall hinzufügen, mit festem Datum oder ab einem erfassten Fakt berechnet.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
titleerforderlichstringWhat must be done by then, in one line (at most 200 characters)
dueAtstring (date) | string (date-time)The due date. A day "YYYY-MM-DD" is due at the end of that day where the case applies (its country, else the owner's); a moment ("2026-03-02T09:00:00+01:00", a hearing) is kept as given
derivedFromobjectCount the date from a recorded date fact instead of giving dueAt: due = the fact's date + offsetDays days, or + offsetMonths calendar months. The deadline moves with the fact when the fact is corrected. Record the fact first with facts_record
kind"HEARING" | "FILING" | "DISCOVERY" | "STATUTE_OF_LIMITATIONS" | "CUSTOM"What kind of deadline it is; CUSTOM when absent
party"SELF" | "COUNTERPARTY"SELF: the owner must act by then. COUNTERPARTY: a window the other side set; SELF when absent
notesstring | nullA short note shown with the deadline and in its reminders (at most 500 characters), or null to clear it
Antwortdaten (201)
FeldTypBeschreibung
caseIderforderlichstring
deadlineerforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/cases/case_abc123/deadlines" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "title": "Protest the termination in writing to the landlord",
  "derivedFrom": {
    "factKey": "receivedAt",
    "offsetMonths": 1
  },
  "kind": "FILING",
  "party": "SELF",
  "notes": "Husleieloven § 9-8 (1): one month from receipt"
}'
PATCH/api/v1/cases/{caseId}/deadlines/{deadlineId}updateCaseDeadline

Eine Frist eines Falls ändern oder als erledigt bzw. wieder offen markieren.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
deadlineIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
titlestringWhat must be done by then, in one line (at most 200 characters)
dueAtstring (date) | string (date-time)The due date. A day "YYYY-MM-DD" is due at the end of that day where the case applies (its country, else the owner's); a moment ("2026-03-02T09:00:00+01:00", a hearing) is kept as given
derivedFromobjectCount the date from a recorded date fact instead of giving dueAt: due = the fact's date + offsetDays days, or + offsetMonths calendar months. The deadline moves with the fact when the fact is corrected. Record the fact first with facts_record
kind"HEARING" | "FILING" | "DISCOVERY" | "STATUTE_OF_LIMITATIONS" | "CUSTOM"What kind of deadline it is; CUSTOM when absent
party"SELF" | "COUNTERPARTY"SELF: the owner must act by then. COUNTERPARTY: a window the other side set; SELF when absent
notesstring | nullA short note shown with the deadline and in its reminders (at most 500 characters), or null to clear it
completedbooleantrue marks the deadline done; false reopens it
Antwortdaten (200)
FeldTypBeschreibung
caseIderforderlichstring
deadlineerforderlichobject
curl
curl -X PATCH "https://attorly.ai/api/v1/cases/case_abc123/deadlines/dl_abc123" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
GET/api/v1/cases/{caseId}/factslistCaseFacts

Die zu einem Fall erfassten Fakten mit ihrer Quelle auflisten, dazu die Fakten, die der Fall noch braucht.

Berechtigung:CASES_READ
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
caseerforderlichobject
factserforderlicharray of object
counterforderlichinteger
caseReadserforderlichobject | nullThe facts the case's rule reads, under exactly these keys; null when it reads none
curl
curl "https://attorly.ai/api/v1/cases/case_abc123/facts" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/cases/{caseId}/factsrecordCaseFact

Einen Fakt zu einem Fall erfassen oder berichtigen. Fristen, die ab ihm berechnet sind, verschieben sich mit.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
keyerforderlichstringThe fact, as a camelCase key. facts_list names the facts this case reads, with their format; use one of those, or another camelCase key only for a fact none of them covers
valueerforderlichstringThe value, in the format its key takes (a date fact: YYYY-MM-DD). It is stored in canonical form, so the result can differ from what was sent ("Lissabon" becomes LIS)
Antwortdaten (200)
FeldTypBeschreibung
caseIderforderlichstring
outcomeerforderlich"recorded" | "corrected" | "unchanged"recorded: a new fact; corrected: a new value replaced the old one; unchanged: it already held this value
facterforderlichobject
movedDeadlineserforderlicharray of objectOpen deadlines counted from the fact that moved with the correction, due days before and after
urlerforderlichstringWhere the case opens in Attorly
curl
curl -X POST "https://attorly.ai/api/v1/cases/case_abc123/facts" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "key": "receivedAt",
  "value": "2026-03-04"
}'
GET/api/v1/cases/{caseId}/partieslistCaseParties

Die Beteiligten eines Falls und die Rollen auflisten, die der Fall vorsieht.

Berechtigung:CASES_READ
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
caseerforderlichobject
partieserforderlicharray of object
counterforderlichinteger
roleserforderlicharray of objectThe roles the case offers; empty when it has no case type with roles
curl
curl "https://attorly.ai/api/v1/cases/case_abc123/parties" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/cases/{caseId}/partiescreateCaseParty

Einen Beteiligten in einer der Rollen eines Falls hinzufügen.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
roleKeyerforderlichstringThe role the party has in the case, as one of the roles parties_list returns (e.g. "landlord")
partyTypeerforderlich"PERSON" | "ENTITY"PERSON for a person, ENTITY for a company or public body
nameerforderlichstringThe party's name (at most 200 characters)
isSelfbooleantrue when this party is the person the connection acts for; false removes that link
orgNumberstringOrganisation number of an ENTITY
personalIdNumberstringNational identity number of a PERSON. Add it only when the owner gave it for this case
emailstring (email)E-mail address
phonestringPhone number
addressstringPostal address
representedBystringThe lawyer or representative acting for the party
notesstringThe owner's note about the party (at most 1000 characters)
positionintegerOrder within its role, 0 first
Antwortdaten (201)
FeldTypBeschreibung
caseIderforderlichstring
partyerforderlichobject
curl
curl -X POST "https://attorly.ai/api/v1/cases/case_abc123/parties" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "roleKey": "landlord",
  "partyType": "ENTITY",
  "name": "Fjord Eiendom AS",
  "orgNumber": "999999999",
  "email": "[email protected]"
}'
PATCH/api/v1/cases/{caseId}/parties/{partyId}updateCaseParty

Die Angaben eines Beteiligten in einem Fall ändern.

Berechtigung:CASES_WRITE
Pfadparameter
FeldTypBeschreibung
caseIderforderlichstring
partyIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
partyType"PERSON" | "ENTITY"PERSON for a person, ENTITY for a company or public body
namestringThe party's name (at most 200 characters)
isSelfbooleantrue when this party is the person the connection acts for; false removes that link
orgNumberstring | null
personalIdNumberstring | null
emailstring (email) | null
phonestring | null
addressstring | null
representedBystring | null
notesstring | null
positionintegerOrder within its role, 0 first
Antwortdaten (200)
FeldTypBeschreibung
caseIderforderlichstring
partyerforderlichobject
curl
curl -X PATCH "https://attorly.ai/api/v1/cases/case_abc123/parties/party_abc123" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"

Vorgänge

GET/api/v1/operations/{operationId}getOperation

Status und Ergebnis einer Anfrage abrufen, die mit Prefer oder Idempotency-Key gesendet wurde.

Pfadparameter
FeldTypBeschreibung
operationIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstringop_…
objecterforderlich"operation"
operationIderforderlichstringThe REST operation that was called, e.g. createRedlines
statuserforderlich"running" | "awaiting_approval" | "succeeded" | "failed"
livemodeerforderlichboolean
idempotencyKeystring | null
resultUrlerforderlichstringWhere to poll: /api/v1/operations/{id}
createdAterforderlichstring (date-time)
completedAterforderlichstring (date-time) | null
expiresAterforderlichstring (date-time)
httpStatuserforderlichinteger | null
resulterforderlichanyThe data of the successful call
metaobject
errorerforderlichobject | null
curl
curl "https://attorly.ai/api/v1/operations/op_abc123" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"

Webhooks

GET/api/v1/webhook-endpointslistWebhookEndpoints

Die Webhook-Endpunkte der Organisation und des Modus des Schlüssels auflisten.

curl
curl "https://attorly.ai/api/v1/webhook-endpoints" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/webhook-endpointscreateWebhookEndpoint

Einen Webhook-Endpunkt anlegen. Die Antwort enthält sein Signiergeheimnis, das nur einmal angezeigt wird.

Anfrageinhalt
FeldTypBeschreibung
urlerforderlichstring (uri)HTTPS URL that receives the events
descriptionstring
enabledEventserforderlicharray of stringEvent types to receive, or ["*"] for all
includeSnapshotsbooleanSend object snapshots instead of thin { id, object } payloads, for operations made with organization API keys (calls made with personal keys and connected apps always send thin payloads). Organization owners and admins only.
Antwortdaten (201)
FeldTypBeschreibung
iderforderlichstringwe_…
objecterforderlich"webhook_endpoint"
urlerforderlichstring
descriptionstring | null
enabledEventserforderlicharray of string
statuserforderlich"enabled" | "disabled"
disabledReasonstring | nulldisabled_by_user or failing_deliveries
livemodeerforderlichboolean
includeSnapshotserforderlichboolean
apiVersionerforderlichstring
failingSincestring (date-time) | null
createdAterforderlichstring (date-time)
updatedAterforderlichstring (date-time)
secretstringwhsec_… — only when the endpoint is created or its secret rolled
curl
curl -X POST "https://attorly.ai/api/v1/webhook-endpoints" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "url": "https://example.com/attorly/webhooks",
  "description": "Production receiver",
  "enabledEvents": [
    "analysis.completed",
    "operation.succeeded",
    "operation.failed"
  ]
}'
GET/api/v1/webhook-endpoints/{endpointId}getWebhookEndpoint

Einen Webhook-Endpunkt abrufen.

Pfadparameter
FeldTypBeschreibung
endpointIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstringwe_…
objecterforderlich"webhook_endpoint"
urlerforderlichstring
descriptionstring | null
enabledEventserforderlicharray of string
statuserforderlich"enabled" | "disabled"
disabledReasonstring | nulldisabled_by_user or failing_deliveries
livemodeerforderlichboolean
includeSnapshotserforderlichboolean
apiVersionerforderlichstring
failingSincestring (date-time) | null
createdAterforderlichstring (date-time)
updatedAterforderlichstring (date-time)
secretstringwhsec_… — only when the endpoint is created or its secret rolled
curl
curl "https://attorly.ai/api/v1/webhook-endpoints/your_endpointId" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
PATCH/api/v1/webhook-endpoints/{endpointId}updateWebhookEndpoint

URL, Ereignisse oder Snapshots eines Endpunkts ändern oder ihn deaktivieren und aktivieren.

Pfadparameter
FeldTypBeschreibung
endpointIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
urlstring (uri)
descriptionstring | null
enabledEventsarray of string
includeSnapshotsboolean
status"enabled" | "disabled"Disable to pause deliveries; enable to resume
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstringwe_…
objecterforderlich"webhook_endpoint"
urlerforderlichstring
descriptionstring | null
enabledEventserforderlicharray of string
statuserforderlich"enabled" | "disabled"
disabledReasonstring | nulldisabled_by_user or failing_deliveries
livemodeerforderlichboolean
includeSnapshotserforderlichboolean
apiVersionerforderlichstring
failingSincestring (date-time) | null
createdAterforderlichstring (date-time)
updatedAterforderlichstring (date-time)
secretstringwhsec_… — only when the endpoint is created or its secret rolled
curl
curl -X PATCH "https://attorly.ai/api/v1/webhook-endpoints/your_endpointId" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
DELETE/api/v1/webhook-endpoints/{endpointId}deleteWebhookEndpoint

Einen Webhook-Endpunkt und seinen Zustellverlauf löschen.

Pfadparameter
FeldTypBeschreibung
endpointIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstring
objecterforderlich"webhook_endpoint"
deletederforderlichtrue
curl
curl -X DELETE "https://attorly.ai/api/v1/webhook-endpoints/your_endpointId" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
POST/api/v1/webhook-endpoints/{endpointId}/secret-rollsrollWebhookEndpointSecret

Das Signiergeheimnis ersetzen. Das alte signiert noch 24 Stunden mit.

Pfadparameter
FeldTypBeschreibung
endpointIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstringwe_…
objecterforderlich"webhook_endpoint"
urlerforderlichstring
descriptionstring | null
enabledEventserforderlicharray of string
statuserforderlich"enabled" | "disabled"
disabledReasonstring | nulldisabled_by_user or failing_deliveries
livemodeerforderlichboolean
includeSnapshotserforderlichboolean
apiVersionerforderlichstring
failingSincestring (date-time) | null
createdAterforderlichstring (date-time)
updatedAterforderlichstring (date-time)
secretstringwhsec_… — only when the endpoint is created or its secret rolled
curl
curl -X POST "https://attorly.ai/api/v1/webhook-endpoints/your_endpointId/secret-rolls" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
POST/api/v1/webhook-endpoints/{endpointId}/test-eventssendWebhookTestEvent

Ein webhook_endpoint.test-Ereignis nur an diesen Endpunkt senden.

Pfadparameter
FeldTypBeschreibung
endpointIderforderlichstring
Antwortdaten (202)
FeldTypBeschreibung
eventIderforderlichstring
curl
curl -X POST "https://attorly.ai/api/v1/webhook-endpoints/your_endpointId/test-events" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
GET/api/v1/webhook-endpoints/{endpointId}/deliverieslistWebhookDeliveries

Die Zustellungen eines Endpunkts auflisten, neueste zuerst, mit Versuchen und Ergebnis.

Pfadparameter
FeldTypBeschreibung
endpointIderforderlichstring
Abfrageparameter
FeldTypBeschreibung
limitintegerItems per page, 1–100 (default 20)
cursorstringThe nextCursor of the previous page
status"pending" | "succeeded" | "failed"Only deliveries in this state
curl
curl "https://attorly.ai/api/v1/webhook-endpoints/your_endpointId/deliveries" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"

Ereignisse

GET/api/v1/eventslistEvents

Die Ereignisse der letzten 30 Tage auflisten, neueste zuerst.

Abfrageparameter
FeldTypBeschreibung
limitintegerItems per page, 1–100 (default 20)
cursorstringThe nextCursor of the previous page
typestringOnly events of this type, e.g. analysis.completed
curl
curl "https://attorly.ai/api/v1/events" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/events/{eventId}getEvent

Ein Ereignis so abrufen, wie Webhook-Endpunkte es erhalten.

Pfadparameter
FeldTypBeschreibung
eventIderforderlichstring
Antwortdaten (200)
FeldTypBeschreibung
iderforderlichstringevt_… — also sent as the webhook-id header; deduplicate on it
objecterforderlich"event"
typeerforderlich"analysis.completed" | "analysis.failed" | "redlines.generated" | "due_diligence.report.completed" | "operation.succeeded" | "operation.failed" | …
apiVersionerforderlichstring
createdAterforderlichstring (date-time)
livemodeerforderlichboolean
dataerforderlichobject
curl
curl "https://attorly.ai/api/v1/events/your_eventId" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
POST/api/v1/events/{eventId}/redeliveriesredeliverEvent

Ein Ereignis erneut senden, an einen Endpunkt oder an alle, die es abonniert haben.

Pfadparameter
FeldTypBeschreibung
eventIderforderlichstring
Anfrageinhalt
FeldTypBeschreibung
endpointIdstringOnly this endpoint; default every endpoint subscribed to the event
Antwortdaten (202)
FeldTypBeschreibung
eventIderforderlichstring
deliveriesSchedulederforderlichinteger
curl
curl -X POST "https://attorly.ai/api/v1/events/your_eventId/redeliveries" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
  "endpointId": "we_abc123"
}'

Konto, Nutzung und Protokolle

GET/api/v1/organizationgetOrganization

Die Organisation des Schlüssels: Tarif, KI-Guthaben, Standardrechtsordnung und was der Schlüssel darf.

Antwortdaten (200)
FeldTypBeschreibung
organizationerforderlichobject
usererforderlichobject
planerforderlichstringSTANDARD, PRO or ENTERPRISE
billingerforderlichobject
defaultJurisdictionerforderlichstring | nullISO 3166-1 alpha-2 country used when a document names no governing law
credentialerforderlichobject
appUrlerforderlichstring
curl
curl "https://attorly.ai/api/v1/organization" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/usagegetUsage

Anfragen pro Tag, Schlüssel und Operation mit Fehlerzahlen, über REST und MCP.

Abfrageparameter
FeldTypBeschreibung
fromanyISO 8601 date; default 30 days ago (requests are kept 30 days)
toanyISO 8601 date, exclusive; default now
curl
curl "https://attorly.ai/api/v1/usage" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/request-logslistRequestLogs

Die API-Anfragen der Organisation aus den letzten 30 Tagen auflisten, neueste zuerst.

Abfrageparameter
FeldTypBeschreibung
limitintegerItems per page, 1–100 (default 20)
cursorstringThe nextCursor of the previous page
statusstring2xx, 4xx, 5xx, or an exact status
credentialIdstringOnly requests made with this key (apikey:<id>, or an MCP connection id)
operationIdstringOnly calls of this operation, e.g. createRedlines
requestIdstringOne request, by its Request-Id
sinceanyISO 8601; only requests at or after this time
untilanyISO 8601; only requests before this time
curl
curl "https://attorly.ai/api/v1/request-logs" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
GET/api/v1/audit-eventslistAuditEvents

Wer hat was wann mit welchem Schlüssel aufgerufen. Für Inhaber und Administratoren der Organisation.

Abfrageparameter
FeldTypBeschreibung
limitintegerItems per page, 1–100 (default 20)
cursorstringThe nextCursor of the previous page
statusstring2xx, 4xx, 5xx, or an exact status
credentialIdstringOnly requests made with this key (apikey:<id>, or an MCP connection id)
operationIdstringOnly calls of this operation, e.g. createRedlines
requestIdstringOne request, by its Request-Id
sinceanyISO 8601; only requests at or after this time
untilanyISO 8601; only requests before this time
curl
curl "https://attorly.ai/api/v1/audit-events" \
  -H "Authorization: Bearer $ATTORLY_API_KEY"
DELETE/api/v1/test-datadeleteTestData

Alle Testobjekte, Ereignisse und Operationen der Organisation löschen. Nur mit Testschlüsseln.

Antwortdaten (200)
FeldTypBeschreibung
objecterforderlich"test_data_purge"
deletederforderlichobject
curl
curl -X DELETE "https://attorly.ai/api/v1/test-data" \
  -H "Authorization: Bearer $ATTORLY_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"