Users

Update user

Updates the user details for the specified ID

PUThttps://api.laminar.run/users/{id}
Path parameters
id*integer (int64)
Body
idinteger (int64)
firstName*string
lastName*string
email*string
workspaces*array of UserWorkspace (object)
Response

User updated successfully

Body
idinteger (int64)
firstName*string
lastName*string
email*string
workspaces*array of UserWorkspace (object)
Request
const response = await fetch('https://api.laminar.run/users/{id}', {
    method: 'PUT',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "email": "text",
      "firstName": "text",
      "lastName": "text",
      "workspaces": [
        {
          "role": "OWNER"
        }
      ]
    }),
});
const data = await response.json();
Response
{
  "firstName": "text",
  "lastName": "text",
  "email": "text",
  "workspaces": [
    {
      "workspace": {
        "name": "text"
      },
      "role": "OWNER"
    }
  ]
}

Delete user

Deletes the user with the specified ID

DELETEhttps://api.laminar.run/users/{id}
Path parameters
id*integer (int64)
Response

User deleted successfully

Request
const response = await fetch('https://api.laminar.run/users/{id}', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();

Get current user

Retrieves the current authenticated user's details

GEThttps://api.laminar.run/users
Response

User details retrieved successfully

Body
idinteger (int64)
firstName*string
lastName*string
email*string
workspaces*array of UserWorkspace (object)
Request
const response = await fetch('https://api.laminar.run/users', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "firstName": "text",
  "lastName": "text",
  "email": "text",
  "workspaces": [
    {
      "workspace": {
        "name": "text"
      },
      "role": "OWNER"
    }
  ]
}

Create a new user

Creates a new user with the provided details

POSThttps://api.laminar.run/users
Body
idinteger (int64)
firstName*string
lastName*string
email*string
workspaces*array of UserWorkspace (object)
Response

User created successfully

Body
idinteger (int64)
firstName*string
lastName*string
email*string
workspaces*array of UserWorkspace (object)
Request
const response = await fetch('https://api.laminar.run/users', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "email": "text",
      "firstName": "text",
      "lastName": "text",
      "workspaces": [
        {
          "role": "OWNER"
        }
      ]
    }),
});
const data = await response.json();
Response
{
  "firstName": "text",
  "lastName": "text",
  "email": "text",
  "workspaces": [
    {
      "workspace": {
        "name": "text"
      },
      "role": "OWNER"
    }
  ]
}