This section provides documentation for the NexWrite API.

Welcome

The NexWrite API allows you to programmatically access and manage blog posts, user accounts, authentication, and settings. This section outlines how to authenticate and start using the available endpoints.

Authentication

All API endpoints require Bearer token authentication. After signing in, the server returns a JWT token which must be included in the Authorization header for any protected request.

"security": [
  {
    "bearerAuth": []
  }
]

How to Get a Token

Send a POST request to:

/api/auth/login

With the following body:

{
  "email": "admin@example.com",
  "password": "your_password"
}

The server will respond with a token:

{
  "token": "your-jwt-token"
}

Use this token in the Authorization header:

Authorization: Bearer your-jwt-token

You can now access protected endpoints such as /api/posts, /api/users, /api/settings, etc.

The token is automatically stored and used in the frontend after login.

This section provides documentation for the NexWrite API.

Welcome

The NexWrite API allows you to programmatically access and manage blog posts, user accounts, authentication, and settings. This section outlines how to authenticate and start using the available endpoints.

Authentication

All API endpoints require Bearer token authentication. After signing in, the server returns a JWT token which must be included in the Authorization header for any protected request.

"security": [
  {
    "bearerAuth": []
  }
]

How to Get a Token

Send a POST request to:

/api/auth/login

With the following body:

{
  "email": "admin@example.com",
  "password": "your_password"
}

The server will respond with a token:

{
  "token": "your-jwt-token"
}

Use this token in the Authorization header:

Authorization: Bearer your-jwt-token

You can now access protected endpoints such as /api/posts, /api/users, /api/settings, etc.

The token is automatically stored and used in the frontend after login.