v1.0.0
OpenAPI 3.0.3
7 endpoints

Example Project API

Sample OpenAPI specification for a basic SaaS-style backend.

Base URLs

  • https://api.example.com/v1

    Production server

  • http://localhost:3000/v1

    Local development server

Authentication

  • bearerAuthHTTP Bearer (JWT)

Auth

Authenticate users and obtain access tokens.

post/auth/login

Login user

Request bodyrequired

application/json

Body

LoginRequest
  • emailstringrequired

    Example: "user@example.com"

  • passwordstringrequired

    Example: "password123"

Responses

  • 200

    Successful login

    application/json

    Response schema

    Response 200

    AuthResponse
    • tokenstring
    • userUser
      Show child attributes
      • idstring

        Example: "usr_123"

      • namestring
      • emailstring
      • createdAtstring · date-time
  • 401

    Invalid credentials

Users

Manage user accounts.

get/users

Get all users

Requires
bearerAuth (HTTP Bearer (JWT))

Parameters

Query

  • pageinteger

    Default: 1

  • limitinteger

    Default: 10

Responses

  • 200

    List of users

    application/json

    Response schema

    Response 200

    UserList
    • dataUser[]
      Show item attributes
      • idstring

        Example: "usr_123"

      • namestring
      • emailstring
      • createdAtstring · date-time
    • pageinteger
    • totalinteger
post/users

Create user

Requires
bearerAuth (HTTP Bearer (JWT))

Request bodyrequired

application/json

Body

CreateUser
  • namestringrequired
  • emailstringrequired
  • passwordstringrequired

Responses

  • 201

    User created

    application/json

    Response schema

    Response 201

    User
    • idstring

      Example: "usr_123"

    • namestring
    • emailstring
    • createdAtstring · date-time
get/users/{id}

Get user by ID

Requires
bearerAuth (HTTP Bearer (JWT))

Parameters

Path

  • idstringrequired

Responses

  • 200

    User data

    application/json

    Response schema

    Response 200

    User
    • idstring

      Example: "usr_123"

    • namestring
    • emailstring
    • createdAtstring · date-time
  • 404

    User not found

put/users/{id}

Update user

Requires
bearerAuth (HTTP Bearer (JWT))

Parameters

Path

  • idstringrequired

Request body

application/json

Body

UpdateUser
  • namestring
  • emailstring

Responses

  • 200

    Updated user

    application/json

    Response schema

    Response 200

    User
    • idstring

      Example: "usr_123"

    • namestring
    • emailstring
    • createdAtstring · date-time
delete/users/{id}

Delete user

Requires
bearerAuth (HTTP Bearer (JWT))

Parameters

Path

  • idstringrequired

Responses

  • 204

    Deleted successfully

Projects

Create and manage projects.

get/projects

Get projects

Requires
bearerAuth (HTTP Bearer (JWT))

Responses

  • 200

    Project list

    application/json

    Response schema

    Response 200

    ProjectList
    • dataProject[]
      Show item attributes
      • idstring
      • titlestring
      • ownerIdstring