Skip to main content

Quickstart Guide

This guide will help you create your first document and send it for signing using the sajn API.

Prerequisites

Before you begin, make sure you have:
  • A sajn account with API access
  • Your API key (found in Organization Settings > API Keys)
  • A tool to make HTTP requests (cURL, Postman, or your favorite programming language)

Step 1: Create a Contact

First, create a contact who will sign the document.
curl -X POST https://app.sajn.se/api/v1/contacts \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "firstName": "John",
    "lastName": "Doe",
    "email": "john.doe@example.com"
  }'
Save the returned id - you’ll need it in the next step.

Step 2: Create a Document

Create a new document in draft status.
curl -X POST https://app.sajn.se/api/v1/documents \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Employment Contract",
    "type": "SIGNABLE"
  }'
Save the returned documentId.

Step 3: Add a Signer

Add your contact as a signer to the document with delivery and signature settings.
curl -X POST https://app.sajn.se/api/v1/documents/{documentId}/signers \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "contactId": "CONTACT_ID_FROM_STEP_1",
    "role": "SIGNER",
    "deliveryMethod": "EMAIL",
    "requiredSignature": "DRAWING"
  }'

Step 4: Send for Signing

Send the document to the signer.
curl -X POST https://app.sajn.se/api/v1/documents/{documentId}/send \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
That’s it! The signer will receive an email with a link to sign the document (based on their deliveryMethod setting).

Next Steps

Postman Collections

Import ready-made requests and environments

Core Concepts

Learn about documents, signers, and workflows

Create Document Guide

Detailed guide on creating documents

API Reference

Explore all available endpoints

Webhooks

Get real-time notifications