Method: limits.getLabel

Obtenez les contraintes sur la structure d'un libellé, comme le nombre maximal de champs autorisés et la longueur maximale du titre du libellé.

Requête HTTP

GET https://drivelabels.googleapis.com/v2/limits/label

L'URL utilise la syntaxe de transcodage gRPC.

Paramètres de requête

Paramètres
name

string

Obligatoire. Le nom de ressource de la révision du libellé doit être "limits/label".

Corps de la requête

Le corps de la requête doit être vide.

Corps de la réponse

Contraintes de libellé régissant la structure d'un libellé, comme le nombre maximal de champs autorisés et la longueur maximale du titre du libellé.

Si la requête aboutit, le corps de la réponse contient des données qui ont la structure suivante :

Représentation JSON
{
  "name": string,
  "maxTitleLength": integer,
  "maxDescriptionLength": integer,
  "maxFields": integer,
  "maxDeletedFields": integer,
  "maxDraftRevisions": integer,
  "fieldLimits": {
    object (FieldLimits)
  }
}
Champs
name

string

Nom de la ressource.

maxTitleLength

integer

Nombre maximal de caractères autorisés pour le titre.

maxDescriptionLength

integer

Nombre maximal de caractères autorisés pour la description.

maxFields

integer

Nombre maximal de champs autorisés dans le libellé.

maxDeletedFields

integer

Nombre maximal de champs publiés pouvant être supprimés.

maxDraftRevisions

integer

Nombre maximal de révisions provisoires à conserver avant la suppression des anciennes.

fieldLimits

object (FieldLimits)

Limites pour les champs.

Champs d'application des autorisations

Nécessite l'un des champs d'application OAuth suivants :

  • https://www.googleapis.com/auth/drive.labels
  • https://www.googleapis.com/auth/drive.labels.readonly
  • https://www.googleapis.com/auth/drive.admin.labels
  • https://www.googleapis.com/auth/drive.admin.labels.readonly

Pour en savoir plus, consultez le guide d'autorisation.

FieldLimits

Constantes de champ régissant la structure d'un champ, telles que la longueur maximale du titre, la longueur ou les valeurs minimale et maximale du champ, etc.

Représentation JSON
{
  "maxIdLength": integer,
  "maxDisplayNameLength": integer,
  "maxDescriptionLength": integer,
  "textLimits": {
    object (TextLimits)
  },
  "longTextLimits": {
    object (LongTextLimits)
  },
  "integerLimits": {
    object (IntegerLimits)
  },
  "dateLimits": {
    object (DateLimits)
  },
  "userLimits": {
    object (UserLimits)
  },
  "selectionLimits": {
    object (SelectionLimits)
  }
}
Champs
maxIdLength

integer

Longueur maximale de l'ID.

maxDisplayNameLength

integer

Limites pour le titre du champ.

maxDescriptionLength

integer

Limites pour la description des champs, également appelée texte d'aide.

textLimits

object (TextLimits)

Limites applicables au Field.Type spécifié. Limites des champs de texte.

longTextLimits

object (LongTextLimits)

Limites de longueur pour les champs de texte long.

integerLimits

object (IntegerLimits)

Limites des champs entiers.

dateLimits

object (DateLimits)

Limites des champs de date.

userLimits

object (UserLimits)

Limites des champs utilisateur.

selectionLimits

object (SelectionLimits)

Limites du champ de sélection.

TextLimits

Limites pour le type de champ de texte.

Représentation JSON
{
  "minLength": integer,
  "maxLength": integer
}
Champs
minLength

integer

Longueur minimale autorisée pour un champ de texte.

maxLength

integer

Longueur maximale autorisée pour un type de champ de texte.

LongTextLimits

Limites pour le type de champ de texte long.

Représentation JSON
{
  "minLength": integer,
  "maxLength": integer
}
Champs
minLength

integer

Longueur minimale autorisée pour un champ de texte long.

maxLength

integer

Longueur maximale autorisée pour un champ de texte long.

IntegerLimits

Limites pour le type de champ entier.

Représentation JSON
{
  "minValue": string,
  "maxValue": string
}
Champs
minValue

string (int64 format)

Valeur minimale pour un type de champ entier.

maxValue

string (int64 format)

Valeur maximale pour un type de champ entier.

DateLimits

Limites pour le type de champ de date.

Représentation JSON
{
  "minValue": {
    object (Date)
  },
  "maxValue": {
    object (Date)
  }
}
Champs
minValue

object (Date)

Valeur minimale pour le type de champ "Date".

maxValue

object (Date)

Valeur maximale pour le type de champ "Date".

UserLimits

Limites pour Field.Type.USER.

Représentation JSON
{
  "listLimits": {
    object (ListLimits)
  }
}
Champs
listLimits

object (ListLimits)

Limites pour la variante de liste d'un type de champ.

ListLimits

Limites pour la variante de liste d'un type de champ.

Représentation JSON
{
  "maxEntries": integer
}
Champs
maxEntries

integer

Nombre maximal de valeurs autorisées pour le type de champ.

SelectionLimits

Limites pour le type de champ de sélection.

Représentation JSON
{
  "listLimits": {
    object (ListLimits)
  },
  "maxIdLength": integer,
  "maxDisplayNameLength": integer,
  "maxChoices": integer,
  "maxDeletedChoices": integer
}
Champs
listLimits

object (ListLimits)

Limites pour la variante de liste d'un type de champ.

maxIdLength

integer

Longueur maximale de l'ID pour une option de sélection.

maxDisplayNameLength

integer

Longueur maximale du nom à afficher.

maxChoices

integer

Nombre maximal de choix.

maxDeletedChoices

integer

Nombre maximal de choix supprimés.