GET /api/roles
Afficher tous les rôles

Paramètres

Nom du paramètre Description
location_id
optionel

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
optionel

Set the current organization context for the request

Validations:

  • Must be a Integer

search
optionel

filtrer les résultats

Validations:

  • Must be a String

order
optionel

Champ et sens de tri, ex: 'id DESC'

Validations:

  • Must be a String

page
optionel

Numéro de la page, commençant par 1

Validations:

  • Must be a number.

per_page
optionel

Nombre de résultats par page à renvoyer

Validations:

  • Must be a number.

Rechercher les champs

Nom du champ Type Valeurs possibles
builtin true, false
description
name
permission string

GET /api/roles/:id
Afficher un rôle

Paramètres

Nom du paramètre Description
location_id
optionel

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
optionel

Set the current organization context for the request

Validations:

  • Must be a Integer

id
requis

Validations:

  • Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.

description
optionel

Validations:

  • Must be a String


POST /api/roles
Créer un rôle

Paramètres

Nom du paramètre Description
location_id
optionel

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
optionel

Set the current organization context for the request

Validations:

  • Must be a Integer

role
requis

Validations:

  • Must be a Hash

role[name]
requis

Validations:

  • Must be a String

role[description]
optionel , nil autorisé

Description du rôle

Validations:

  • Must be a String

role[location_ids]
optionel , nil autorisé

REMPLACER les emplacements par les id donnés

Validations:

  • Must be an array of any type

role[organization_ids]
optionel , nil autorisé

REMPLACER les organisations qui ont les ID suivants

Validations:

  • Must be an array of any type


PUT /api/roles/:id
Mise à jour d'un rôle

Paramètres

Nom du paramètre Description
location_id
optionel

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
optionel

Set the current organization context for the request

Validations:

  • Must be a Integer

id
requis

Validations:

  • Must be a String

role
requis

Validations:

  • Must be a Hash

role[name]
optionel

Validations:

  • Must be a String

role[description]
optionel , nil autorisé

Description du rôle

Validations:

  • Must be a String

role[location_ids]
optionel , nil autorisé

REMPLACER les emplacements par les id donnés

Validations:

  • Must be an array of any type

role[organization_ids]
optionel , nil autorisé

REMPLACER les organisations qui ont les ID suivants

Validations:

  • Must be an array of any type


DELETE /api/roles/:id
Supprimer un rôle

Paramètres

Nom du paramètre Description
location_id
optionel

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
optionel

Set the current organization context for the request

Validations:

  • Must be a Integer

id
requis

Validations:

  • Must be a String


POST /api/roles/:id/clone
Cloner un rôle

Paramètres

Nom du paramètre Description
location_id
optionel

Set the current location context for the request

Validations:

  • Must be a Integer

organization_id
optionel

Set the current organization context for the request

Validations:

  • Must be a Integer

id
requis

Validations:

  • Must be a String

role
requis

Validations:

  • Must be a Hash

role[name]
optionel

Validations:

  • Must be a String

role[description]
optionel , nil autorisé

Description du rôle

Validations:

  • Must be a String

role[location_ids]
optionel , nil autorisé

REMPLACER les emplacements par les id donnés

Validations:

  • Must be an array of any type

role[organization_ids]
optionel , nil autorisé

REMPLACER les organisations qui ont les ID suivants

Validations:

  • Must be an array of any type