Voedger Internals
  • Introduction
  • 💡Concepts
    • Event Sourcing & CQRS
    • Editions (deprecated)
      • Community Edition
      • Standart Edition
      • Standart Edition (v1)
  • 🚀Server
    • Overview (Server)
    • Design
      • Query Processor
      • API Gateway implementation
      • N1 Cluster
      • N3 Cluster
      • N5 Cluster
      • Orchestration
      • Sequences
      • Packages overview
        • sys
        • registry
    • Features
      • API Gateway
        • API v2
          • Conventions
            • API URL
            • HTTP methods and processors
            • Naming conventions
            • Query constraints
            • Error handling
          • Documents and records
            • Create document or record
            • Update document or record
            • Deactivate document or record
            • Read document or record
            • Read from CDoc collection
          • Queries
            • Read from query
          • Views
            • Read from view
          • Commands
            • Execute command
          • BLOBs
            • Create BLOB
            • Read BLOB
          • Temporary BLOBs
            • Create temporary BLOB
            • Read temporary BLOB
          • Schemas
            • List app workspaces
            • List workspace roles
            • Read workspace role schema
        • API v1
          • API Conventions
          • BLOBs
      • Admin Endpoint
      • Clusters
        • Bootstrap
        • Monitoring
        • Secure prometheus and grafana
        • Alerting
        • Maintenance
          • SELECT, UPDATE
      • VVMs
      • Applications
        • Deploy Application
        • Sidecar Applications
      • AuthNZ
        • Issue Principal Token
        • Refresh Principal Token
        • Enrich Principal Token
        • ACL Rules
        • Global Roles
      • Data types
        • Core types
        • Small integers
        • Uniques With Multiple Fields
        • Verifiable Fields
      • Workspaces
        • Create Workspace
        • Deactivate Workspace
        • See also (Workspaces)
      • Invites
        • Invite to Workspace
        • Join Workspace
        • Leave Workspace
        • Cancel sent Invite
        • Cancel accepted Invite
        • Update Invite roles
      • Users
        • Create a new user
        • Change user password
        • Send Email
        • Reset password
        • Change Email
      • Notifications
        • Heartbeats
      • Devices
        • Create a new device
        • Join device to workspace
      • Jobs
      • DMBS Drivers
        • AmazonDB Driver
      • Frozen
        • Ephemeral Storage
        • Storage Extensions
  • 🛠️Framework
    • Overview (Framework)
    • Features
      • vpm
      • vpm init
      • vpm tidy
      • vpm baseline
      • vpm orm
      • vpm build
      • API for testing
  • Development
    • Requirements Management
    • Requirements Management (Overview)
Powered by GitBook
On this page
  • Motivation
  • Functional design
  • API Conventions
  • REST API Paths
  • Limitations
  • Addressed issues
  • See Also

Was this helpful?

Edit on GitHub
  1. 🚀Server
  2. Features
  3. API Gateway

API v2

PreviousAPI GatewayNextConventions

Last updated 1 day ago

Was this helpful?

Motivation

  • We need good REST API for Voedger

  • Old API must still be available until the new one is fully developed, so we can continue with AIR

Functional design

API Conventions

REST API Paths

Action
REST API Path

Authentication

POST /api/v2/apps/{owner}/{app}/auth/login

POST /api/v2/apps/{owner}/{app}/auth/refresh

Logins

POST /api/v2/apps/{owner}/{app}/users

POST /api/v2/apps/{owner}/{app}/users/change-password

Devices

POST /api/v2/apps/{owner}/{app}/devices

POST /api/v2/apps/{owner}/{app}/workspaces/{wsid}/commands/sys.JoinDevice

Docs and records

POST /api/v2/apps/{owner}/{app}/workspaces/{wsid}/docs/{pkg}.{table}

PATCH /api/v2/apps/{owner}/{app}/workspaces/{wsid}/docs/{pkg}.{table}/{id}

DELETE /api/v2/apps/{owner}/{app}/workspaces/{wsid}/docs/{pkg}.{table}/{id}

GET /api/v2/apps/{owner}/{app}/workspaces/{wsid}/docs/{pkg}.{table}/{id}

GET /api/v2/apps/{owner}/{app}/workspaces/{wsid}/cdocs/{pkg}.{table}

BLOBs

POST /api/v2/apps/{owner}/{app}/workspaces/{wsid}/docs/{pkg}.{table}/blobs/{fieldName}

GET /api/v2/apps/{owner}/{app}/workspaces/{wsid}/docs/{pkg}.{table}/{id}/blobs/{fieldName}

Temporary BLOBs

POST /api/v2/apps/{owner}/{app}/workspaces/{wsid}/tblobs

GET /api/v2/apps/{owner}/{app}/workspaces/{wsid}/tblobs/{suuid}

Extensions

POST /api/v2/apps/{owner}/{app}/workspaces/{wsid}/commands/{pkg}.{command}

GET /api/v2/apps/{owner}/{app}/workspaces/{wsid}/queries/{pkg}.{query}

Views

GET /api/v2/apps/{owner}/{app}/workspaces/{wsid}/views/{pkg}.{view}

Notifications

Create channel, subscribe and start watching

POST /api/v2/apps/{owner}/{app}/workspaces/{wsid}/n10n

Update channel subscriptions and continue watching

PATCH /api/v2/apps/{owner}/{app}/workspaces/{wsid}/n10n/{channelId}

Unsubscribe from notifications channel

DELETE /api/v2/apps/{owner}/{app}/workspaces/{wsid}/n10n/{channelId}

Schemas

GET /api/v2/apps/{owner}/{app}/schemas

GET /api/v2/apps/{owner}/{app}/schemas/{pkg}.{workspace}/roles

GET /api/v2/apps/{owner}/{app}/schemas/{pkg}.{workspace}/roles/{pkg}.{role}

Limitations

  • The following functions should not be calle directly:

    • c.sys.CUD

    • q.sys.Collection

Addressed issues

See Also

API URL
HTTP methods and processors
Naming conventions
Query constraints
Error handling
API Gateway (APIv2) #1162
Query Processor
API Gateway Implementation
Creates a new principal token
Refreshes a valid principal token
Create(register) a new user
Change user password
Create(register) a new device
Join device to workspace
Create document or record
Update document or record
Deactivate document or record
Read document or record
Read from CDoc Collection
Create BLOB
Read BLOB
Create temporary BLOB
Read temporary BLOB
Execute Command
Read from Query
Read from View
List app workspaces
List workspace roles
Read workspace role schema