# Admin Directory API . groups . aliases

## Instance Methods

Remove a alias for the group

Add a alias for the group

List all aliases for a group

### Method Details

`delete(groupKey, alias)`

    Remove a alias for the group

    Args:
      groupKey: string, Email or immutable ID of the group (required)
      alias: string, The alias to be removed (required)

`insert(groupKey, body)`

    Add a alias for the group

    Args:
      groupKey: string, Email or immutable ID of the group (required)
      body: object, The request body. (required)
        The object takes the form of:

    { # JSON template for Alias object in Directory API.
        "alias": "A String", # A alias email
        "kind": "admin#directory#alias", # Kind of resource this is.
        "etag": "A String", # ETag of the resource.
        "primaryEmail": "A String", # Group's primary email (Read-only) User's primary email (Read-only)
        "id": "A String", # Unique id of the group (Read-only) Unique id of the user (Read-only)
      }

    Returns:
      An object of the form:

        { # JSON template for Alias object in Directory API.
          "alias": "A String", # A alias email
          "kind": "admin#directory#alias", # Kind of resource this is.
          "etag": "A String", # ETag of the resource.
          "primaryEmail": "A String", # Group's primary email (Read-only) User's primary email (Read-only)
          "id": "A String", # Unique id of the group (Read-only) Unique id of the user (Read-only)
        }

`list(groupKey)`

    List all aliases for a group

    Args:
      groupKey: string, Email or immutable ID of the group (required)

    Returns:
      An object of the form:

        { # JSON response template to list aliases in Directory API.
        "kind": "admin#directory#aliases", # Kind of resource this is.
        "etag": "A String", # ETag of the resource.
        "aliases": [ # List of alias objects.
          "",
        ],
      }