ОUЯUKΛ / Documentation
DE EN

Introduction

Ouruka is a cloud-native REST API service for generating unique, structured IDs. It is designed for developers and system integrators who need reliably unique identifiers in their applications — without having to implement counter logic, date stamps, or uniqueness guarantees themselves.

Typical Use Cases

  • Product Information Systems (PIM): Consistent article and product numbers across multiple sales channels.
  • ERP Systems: Document numbers, order numbers, and delivery note numbers in a uniform format.
  • Webshops & E-Commerce: Order numbers, customer numbers, and transaction IDs.
  • Logistics: Shipment numbers, pallet IDs, and shipping labels.
  • Healthcare: Patient record numbers, sample IDs, and case numbers.
  • Manufacturing: Serial numbers, batch designations, and quality IDs.

Ouruka runs in production at ouruka.com and is reachable from anywhere. The complete API documentation with interactive testing is available at ouruka.com/swagger/.

Quick Start

Three steps to your first generated ID:

  1. Choose a plan & register

    Select a plan (Discovery, Solar, Galaxy, or Universe) and complete registration. The system automatically creates your personal tenant — your isolated workspace within the Ouruka system — and issues you an api_key exactly once.

    Store your API key securely — it is issued only once and is required for all subsequent API calls.

  2. Create a schema

    A schema defines the format of your IDs. You specify which building blocks — date, counter, fixed characters, variables — make up an ID.

    HTTP Request
    POST /v2/schema
    X-API-KEY: <your API key>
    
    {
      "name":    "order-number",
      "pattern": "ORD-{DATE:YYYY}{DATE:MM}-{COUNTER:5}"
    }

    This pattern generates IDs like ORD-202503-00001.

  3. Generate an ID

    Using the schema name, request the next ID. Ouruka ensures every generated ID is unique — even under concurrent requests.

    HTTP Request
    POST /v2/id/generate
    X-API-KEY: <your API key>
    
    {
      "schema": "order-number"
    }
    Response 200 OK
    {
      "id": "ORD-202503-00042"
    }

Authentication

All endpoints that read or write data require a valid API key. It is transmitted as an HTTP header:

HTTP Header
X-API-KEY: <your API key>

The API key is automatically issued by the system upon registration. It uniquely identifies your tenant and controls access to all your schemas, counters, and ID histories.

🔐
  • Never store the API key in source code or versioned files.
  • Use environment variables or secret managers (e.g. AWS Secrets Manager, HashiCorp Vault, Kubernetes Secrets).
  • Do not share the key with third parties. Anyone with knowledge of the key can generate IDs on your behalf.
  • The key is transmitted exclusively over HTTPS.

ID Generation with Schemas

Schemas are the core of Ouruka. They define the exact format of an ID through a pattern — a string where fixed text elements are combined with dynamic placeholders.

Pattern → Result
ART-{DATE:YY}{DATE:MM}-{COUNTER:4}ART-2503-0017

{DATE:YYYY}

Inserts the four-digit year at the time of generation (e.g. 2025).

PatternExample IDUse case
FB-{DATE:YYYY}-{COUNTER:6} FB-2025-000134 Logistics · Freight documents
LAB-{DATE:YYYY}-{COUNTER:5} LAB-2025-00891 Healthcare · Lab samples

{DATE:YY}

Inserts the two-digit short form of the year (e.g. 25 for 2025). Saves characters in space-constrained ID fields.

PatternExample IDUse case
JKT-{DATE:YY}{DATE:MM}-{COUNTER:4} JKT-2503-0056 Fashion · Season identification
SN{DATE:YY}{DATE:MM}{COUNTER:6} SN2504001782 Manufacturing · Serial numbers

{DATE:MM}

Inserts the two-digit month at the time of generation (01 through 12).

PatternExample IDUse case
RE-{DATE:YYYY}-{DATE:MM}-{COUNTER:5} RE-2025-03-00421 E-Commerce · Invoices
RET{DATE:YY}{DATE:MM}-{COUNTER:4} RET2503-0088 Logistics · Return slips

{DATE:DD}

Inserts the two-digit day at the time of generation (01 through 31).

PatternExample IDUse case
BON-{DATE:YYYY}{DATE:MM}{DATE:DD}-{COUNTER:4} BON-20250318-0047 Hospitality · Daily receipts
PA-{DATE:DD}{DATE:MM}{DATE:YY}-{COUNTER:3} PA-180325-014 Healthcare · Patient admissions

{COUNTER:N}

Inserts an automatically incrementing, zero-padded numeric counter. N specifies the minimum number of digits. The counter starts at the defined start_value (default: 1) and is incremented by 1 with each ID generation for that schema.

Ouruka guarantees atomicity — even under simultaneous requests from multiple systems, each number is assigned only once. No race conditions, no locking overhead.

ParameterDescription
N Minimum digit count (padded with leading zeros). {COUNTER:4} + value 7 → 0007
start_value Optional starting value when creating the schema. Default is 1.
Patternstart_valueExample IDUse case
ORD-{DATE:YYYY}-{COUNTER:6} 1 ORD-2025-000342 E-Commerce · Order numbers
CH-{DATE:YYYY}-{COUNTER:5} 10000 CH-2025-10047 Pharma · Batch numbers

{VAR1} – {VAR4}

The placeholders {VAR1} through {VAR4} allow you to embed custom values into IDs at generation time. They are not filled automatically — they must be supplied with every generate call — for example country codes, department identifiers, or product groups.

Syntax variants
{VAR1}      — value inserted directly
{VAR1:-}    — value with hyphen as separator
{VAR2:/}    — value with slash as separator

The separator only appears when the value is non-empty — preventing double delimiters in the ID.

PatternVAR1ResultUse case
SEND-{DATE:YYYY}-{VAR1:-}{COUNTER:6} DE SEND-2025-DE-000071 Logistics · Shipment numbers
SEND-{DATE:YYYY}-{VAR1:-}{COUNTER:6} FR SEND-2025-FR-000072 Logistics · Shipment numbers
ART-{VAR1:-}{DATE:YY}-{COUNTER:5} ELEC ART-ELEC-25-00019 PIM · Product numbers
ART-{VAR1:-}{DATE:YY}-{COUNTER:5} FASH ART-FASH-25-00020 PIM · Product numbers

Random IDs (UID)

In addition to structured schema IDs, Ouruka offers random-based unique identifiers. UIDs contain no semantic information like dates or counters — they are purely unique and suited for tokens, API keys, and any scenario where anonymity and randomness are required.

Numeric UIDs

Endpoint
POST /v2/uid/numeric

Generates a random numeric ID of the desired length. Each ID consists exclusively of digits (0–9).

LengthExample UIDUse case
8 73920481 Voucher codes (readable over the phone)
12 829401736254 Barcodes / EAN-compatible serial numbers

Alphanumeric UIDs

Endpoint
POST /v2/uid/alpha

Generates a UID from letters and digits (a–z, A–Z, 0–9). Due to the larger character space, the collision probability is astronomically low even at short lengths — at 16 characters there are nearly 8 quadrillion possible combinations.

LengthExample UIDUse case
24 aX7kP2mRnQz9wLvBcT4eYdJ0 Session tokens, cookies
16 Kf3mX9pLrT2nVqBw Anonymisation IDs for clinical studies

String Conversion (Keyify)

Endpoint
POST /v2/keyify

Keyify converts arbitrary free-text strings into URL-safe, uniformly formatted keys. Typical use cases include URL slugs, database keys, technical identifiers, or SEO-friendly product URLs generated from natural language input.

Transformations

  • Spaces are replaced with hyphens (-)
  • Special characters are removed or converted
  • Casing is unified (lowercase)
  • German umlauts are transliterated: ä→ae, ö→oe, ü→ue, ß→ss
  • Consecutive hyphens are cleaned up

Umlaut Reference

InputOutputInputOutput
äaeÄAe
öoeÖOe
üueÜUe
ßss

Examples

InputOutput (Keyify)Use case
Black Leather Jacket Size XL black-leather-jacket-size-xl E-Commerce · Product URLs
Men's Steel Watch mens-steel-watch E-Commerce · Product URLs
Kühlschränke & Gefriergeräte kuehlschraenke-gefriergerate PIM · Category keys
Sports & Outdoor sports-outdoor PIM · Category keys

History

Ouruka logs every generated ID in a history list that is retrievable per schema. Stored data includes the generated ID, the timestamp (UTC), and optional metadata.

The history allows you to trace which IDs were generated and when — useful for audits, error analysis, and workflows that check for completeness.

Endpoint
GET /v2/history
X-API-KEY: <your API key>

Retention Period by Plan

PlanRetention period
Discovery · TrialLimited number of entries
Solar · StarterSeveral weeks
Galaxy · StandardSeveral months
Universe · FullIndividually configurable

FAQ

Are the IDs truly unique?
Yes. Ouruka guarantees uniqueness within a schema (for schema IDs) or within a tenant (for UIDs). Counters are incremented atomically — even under concurrent requests, each counter value is assigned only once. UIDs are generated with sufficient entropy that collisions are effectively impossible.
What happens if two systems request an ID at the same time?
Ouruka uses atomic Redis operations to structurally eliminate race conditions. Even if hundreds of requests arrive within the same millisecond, each receives a different, unique ID. There are no duplicates — this is not a convention but an architectural guarantee.
Can I reset the counter?
A counter reset is possible via the API. Note that a reset can lead to already-assigned counter values if the pattern remains unchanged. If uniqueness must be guaranteed after a reset, we recommend updating the pattern at the same time — for example by changing a year component or a fixed prefix.
What is the difference between schema IDs and UIDs?
Schema IDs follow a custom-defined pattern and can contain readable, structured information (date, counter, variables). They are ideal wherever the ID itself carries meaning — e.g. document numbers or product codes.

UIDs are purely randomly generated, semantically empty strings. They are suited for technical keys, tokens, and scenarios where the ID should carry no semantic information.
How secure is the API key?
The API key is transmitted exclusively over HTTPS. It is long enough to rule out brute-force attacks. Ouruka does not store API keys in plain text — only as a hash. If a key has been compromised, it can be rotated through tenant management. Always keep the key outside of your source code.
Can I have multiple schemas?
Yes. Each tenant can create any number of schemas. Each schema has its own independent counter, its own history, and its own pattern. Typically you create one schema per entity or document type — for example one for orders, one for invoices, one for customers.
Can I integrate Ouruka into existing systems?
Yes. Ouruka is a standard REST API with JSON payloads. There are no SDK dependencies and no proprietary protocols. Any programming language that can send HTTP requests is compatible — from Python and Java to PHP and low-code platforms like Make or Zapier.

Swagger / API Reference

The complete technical API documentation is available interactively through the Swagger UI — directly in the browser, no external tools needed.

  • Complete endpoint overview: All available API endpoints with methods, paths, and descriptions.
  • Request & response schemas: Exact definitions of all input and output fields, data types, and required fields.
  • Interactive testing: Call endpoints directly in the browser with your own API key.
  • Example requests & responses: Concrete examples for typical use cases.
  • Error codes: Documentation of all HTTP error codes and their meaning.

To use the Swagger UI, click Authorize and enter your X-API-KEY.

Open Swagger UI →