---
title: "Compte"
source: /fr/gcxone/api/account
locale: fr
updated: 2026-09-04
---
Opérations sur les ressources de compte. 11 points de terminaison, chacun relatif à `https://api.nxgen.cloud/api/v1` et authentifié comme décrit sous [Authentification](/gcxone/api/authentication).

## POST /account/

Créer de nouveaux comptes

### Corps de la requête

Ajouter un compte

```json
{
  "payload": {
    "id": "string",
    "name": "string (required)",
    "email": "string (required)",
    "firstName": "string",
    "lastName": "string",
    "isActive": "boolean",
    "profileVisible": "boolean",
    "countryCode": "string",
    "phoneNumber": "string",
    "houseBuildingNumber": "string",
    "streetName": "string",
    "city": "string",
    "state": "string",
    "country": "string",
    "code": "string",
    "logo": "string",
    "latitude": "string",
    "longitude": "string",
    "plusCode": "string",
    "what3Words": "string",
    "business": [
      "string"
    ],
    "tags": [
      "string"
    ],
    "photos": [
      "string"
    ],
    "devImage": "string",
    "followers": [
      "string"
    ],
    "accountType": [
      "Customer"
    ],
    "websiteUrl": "string",
    "jsonSchema": "object",
    "parentJsonSchemaResult": "object",
    "parentAccountId": "string",
    "parent": "string",
    "serviceProvidersEventProviderId": "string",
    "roles": [
      "string"
    ],
    "geoCordinates": "object"
  }
}
```

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Pas de contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

## GET /account/accountByName

Obtenir le compte par nom

### Paramètres

| Nom | Dans | Type | Obligatoire | Description |
| --- | --- | --- | --- | --- |
| nom | requête | chaîne | oui |  |

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Aucun contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

## POST /account/bulkUpdateActiveInactive

mise à jour en masse des sps par identifiant de compte parent

### Corps de la demande

Mettre à jour les SP

```json
{
  "parentAccountId": "string"
}
```

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès | objet |
| 204 | Aucun contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

Exemple `200` réponse:

```json
{
  "data": [
    {
      "key": "7f01237864567eba89736f825",
      "label": "customer",
      "serviceProviderName": "sp"
    }
  ]
}
```

## POST /account/filter

Obtient la liste des comptes avec filtrage, tri et pagination. Permet la recherche par niveau hiérarchique. Peut être filtré en utilisant la hiérarchie spécifiée ou utilise la hiérarchie de l'utilisateur connecté. Cela offre la possibilité d'obtenir des champs d'entité supplémentaires dans la réponse. Fournit également les métadonnées de configuration concernant l'entité.

### Corps de la demande

Filtrage et tri des comptes

```json
{
  "filters": [
    {
      "columnName": "string (required)",
      "type": "distinctList | date | number | StringConditionFilter (required)",
      "filter": "object (required)"
    }
  ],
  "sortOrder": [
    {
      "columnName": "string",
      "isAscending": "boolean"
    }
  ],
  "primaryColumns": [
    "string"
  ],
  "hierarchyLevel": "string",
  "hierarchyId": "string",
  "nPerPage": "number",
  "pageNumber": "number",
  "isConfigDetailRequired": "boolean",
  "getConfig": "boolean",
  "getChildOrParent": "boolean"
}
```

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès | objet |
| 204 | Aucun contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

Exemple `200` réponse :

```json
{
  "config": {
    "columns": [
      {
        "visibility": true,
        "columnName": "commercialName",
        "DisplayName": "Account",
        "isFilterable": true,
        "filterType": "stringCondition",
        "sticky": true,
        "isRightBorder": true,
        "isMandatory": true,
        "isNotDraggable": true
      }
    ],
    "defaultNPerPage": 50,
    "defaultFilterCondition": [],
    "defaultSortingOrder": [
      {
        "columnName": "dateTime",
        "isAscending": false
      }
    ],
    "maxVisibleColumnCount": 6,
    "exportLimitNPerPage": 500
  },
  "dataResult": [
    {
      "name": "app",
      "email": "app@test.com",
      "isActive": "true",
      "phoneNumber": "",
      "streetName": "",
      "city": "",
      "code": "",
      "uniqueId": "da7cf69b4c714f80d8466c714f683a8173cdb",
      "parentAccountId": "acf9b10a2c714f683a8173cdb7f417cf4a4"
    },
    {
      "name": "Customer",
      "email": "customer@test.com",
      "isActive": "true",
      "phoneNumber": "",
      "streetName": "",
      "city": "",
      "code": "",
      "uniqueId": "c714f683a8173cdb58acf9b10a7cf69b",
      "parentAccountId": "acf9b10a2c714f683a8173cdb7f417cf4a4"
    }
  ],
  "totalRecordsCount": 3552,
  "filteredBy": [],
  "sortedBy": [
    {
      "columnName": "dateTime",
      "isAscending": false
    }
  ],
  "dispatchedAll": false,
  "isDefaultProjectionMutated": false,
  "isDefaultFilterMutated": false,
  "isDefaultSortingMutated": false
}
```

## POST /account/listByAccountId

Obtenir les clients par identifiant de compte parent

### Corps de la demande

Obtenir les clients

```json
{
  "parentAccountId": "string"
}
```

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès | objet |
| 204 | Aucun contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

Exemple `200` réponse :

```json
{
  "data": [
    {
      "key": "7f01237864567eba89736f825",
      "label": "customer",
      "serviceProviderName": "sp"
    }
  ]
}
```

## GET /account/{id}

Obtenir le compte par Id

### Paramètres

| Nom | Dans | Type | Obligatoire | Description |
| --- | --- | --- | --- | --- |
| id | path | string | oui |  |

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Pas de contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

## PUT /account/{id}

Mettre à jour un compte existant

### Paramètres

| Nom | Dans | Type | Obligatoire | Description |
| --- | --- | --- | --- | --- |
| id | chemin | string | oui |  |

### Corps de la requête

Pour ajouter ou mettre à jour un compte, fournir l'Id existant

```json
{
  "payload": {
    "id": "string",
    "uniqueId": "string",
    "parent": "string",
    "parentAccountId": "string",
    "email": "string (required)",
    "isActive": "boolean",
    "persona": {
      "address": {
        "houseBuildingNumber": "string",
        "streetName": "string",
        "city": "string",
        "state": "string",
        "code": "string",
        "country": "string"
      },
      "contact": {
        "countryCode": "string",
        "phoneNumber": "string"
      },
      "profile": {
        "logo": "string",
        "business": [
          "…"
        ],
        "photos": [
          "…"
        ],
        "tags": [
          "…"
        ],
        "followers": [
          "…"
        ],
        "s3ImagePath": "string"
      }
    },
    "accountType": [
      "Customer"
    ],
    "name": "string (required)",
    "profileVisible": "boolean",
    "syncStatus": "boolean",
    "jsonSchema": "object",
    "geoCordinates": "object",
    "serviceProvidersEventProviderId": "string"
  }
}
```

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Pas de contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

## DELETE /account/{id}

Supprimer un compte par Id

### Paramètres

| Nom | Dans | Type | Obligatoire | Description |
| --- | --- | --- | --- | --- |
| id | chemin | string | oui |  |

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Pas de contenu |  |
| 400 | Entrée invalide |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |

## GET /account/{parentAccountId}/customer

Obtenir la liste des clients par identifiant parent (N ° de client)

### Paramètres

| Nom | Dans | Type | Obligatoire | Description |
| --- | --- | --- | --- | --- |
| parentAccountId | path | string | oui |  |

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Pas de contenu |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |
| 404 | Pas trouvé |  |

## GET /account/{parentAccountId}/sites/information

Obtenir la liste des sites par identifiant parent (Customer Id)

### Paramètres

| Nom | Dans | Type | Obligatoire | Description |
| --- | --- | --- | --- | --- |
| parentAccountId | path | string | oui |  |

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Pas de contenu |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |
| 404 | Pas trouvé |  |

## GET /account/{parentAccountId}/users

Obtenir la liste des utilisateurs par identifiant parent (N ° de client)

### Paramètres

| Nom | Dans | Type | Obligatoire | Description |
| --- | --- | --- | --- | --- |
| parentAccountId | chemin | string | oui |  |

### Réponses

| Statut | Description | Corps |
| --- | --- | --- |
| 200 | Succès |  |
| 204 | Pas de contenu |  |
| 401 | Non autorisé |  |
| 403 | Interdit |  |
| 404 | Pas trouvé |  |