> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pinkfish.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# google-photos

> Google Photos

**Server path:** `/google-photos` | **Type:** Application | **PCID required:** Yes

## Tools

| Tool                                                                                              | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| ------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [`google-photos_add_enrichment_albums`](#google-photos_add_enrichment_albums)                     | Adds an enrichment at a specified position in an app created created album.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| [`google-photos_batch_add_media_items_albums`](#google-photos_batch_add_media_items_albums)       | Adds one or more app created media items in a user's Google Photos library to an app created album. The media items and albums must have been created by the developer via the API. Media items are added to the end of the album. If multiple media items are given, they are added in the order specified in this call. Each album can contain up to 20,000 media items. Partial success is not supported. The entire request will fail if an invalid media item or album is specified.                                                                                                                                                                                                      |
| [`google-photos_batch_create_media_items`](#google-photos_batch_create_media_items)               | Creates one or more media items in a user's Google Photos library. This is the second step for creating a media item. For details regarding Step 1, uploading the raw bytes to a Google Server, see Uploading media. This call adds the media item to the library. If an app created album `id` is specified, the call adds the media item to the album too. Each album can contain up to 20,000 media items. By default, the media item will be added to the end of the library or album. If an album `id` and position are both defined, the media item is added to the album at the specified position. If the call contains multiple media items, they're added at the specified position. |
| [`google-photos_batch_get_media_items`](#google-photos_batch_get_media_items)                     | Returns the list of app created media items for the specified media item identifiers. Items are returned in the same order as the supplied identifiers.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| [`google-photos_batch_remove_media_items_albums`](#google-photos_batch_remove_media_items_albums) | Removes one or more app created media items from a specified app created album. The media items and the album must have been created by the developer via the API. Partial success is not supported. The entire request will fail and no action will be performed on the album if an invalid media item or album is specified.                                                                                                                                                                                                                                                                                                                                                                 |
| [`google-photos_create_albums`](#google-photos_create_albums)                                     | Creates an album in a user's Google Photos library.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| [`google-photos_get_albums`](#google-photos_get_albums)                                           | Returns the app created album based on the specified `albumId`. The `albumId` must be the ID of an album created by your app.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| [`google-photos_get_media_items`](#google-photos_get_media_items)                                 | Returns the app created media item for the specified media item identifier.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| [`google-photos_get_shared_albums`](#google-photos_get_shared_albums)                             | *Beginning March 31, 2025, this method will no longer work. Some or all of the scopes previously used for this method are being removed. Please see Photos APIs updates for more details.* Returns the album based on the specified `shareToken`.                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| [`google-photos_join_shared_albums`](#google-photos_join_shared_albums)                           | Joins a shared album on behalf of the Google Photos user.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| [`google-photos_leave_shared_albums`](#google-photos_leave_shared_albums)                         | Leaves a previously-joined shared album on behalf of the Google Photos user. The user must not own this album.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| [`google-photos_list_albums`](#google-photos_list_albums)                                         | Lists all albums created by your app.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| [`google-photos_list_media_items`](#google-photos_list_media_items)                               | List all media items created by your app from a user's Google Photos library.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| [`google-photos_list_shared_albums`](#google-photos_list_shared_albums)                           | Lists all shared albums available in the Sharing tab of the user's Google Photos app.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| [`google-photos_patch_albums`](#google-photos_patch_albums)                                       | Update the app created album with the specified `id`. Only the `id`, `title` and `cover_photo_media_item_id` fields of the album are read. The album must have been created by the developer via the API.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| [`google-photos_patch_media_items`](#google-photos_patch_media_items)                             | Update the app created media item with the specified `id`. Only the `id` and `description` fields of the media item are read. The media item must have been created by the developer via the API.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| [`google-photos_search_media_items`](#google-photos_search_media_items)                           | Searches for app created media items in a user's Google Photos library. Only media items and ablums created by your app are returned. If no filters are set, then all app created media items in the user's library are returned. If an app created album is set, all media items in the specified album are returned. If filters are specified, app created media items that match the filters from the user's library are listed. If you set both the album and the filters, the request results in an error.                                                                                                                                                                                |
| [`google-photos_share_albums`](#google-photos_share_albums)                                       | Marks an album as shared and accessible to other users. This action can only be performed on albums which were created by the developer via the API.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| [`google-photos_unshare_albums`](#google-photos_unshare_albums)                                   | Marks a previously shared album as private. This means that the album is no longer shared and all the non-owners will lose access to the album. All non-owner content will be removed from the album. If a non-owner has previously added the album to their library, they will retain all photos in their library. This action can only be performed on albums which were created by the developer via the API.                                                                                                                                                                                                                                                                               |

***

## google-photos\_add\_enrichment\_albums

Adds an enrichment at a specified position in an app created created album.

**Parameters:**

| Parameter           | Type   | Required | Default | Description                                                                                         |
| ------------------- | ------ | -------- | ------- | --------------------------------------------------------------------------------------------------- |
| `albumId`           | string | Yes      | —       | Required. Identifier of the app created album where the enrichment is to be added.                  |
| `albumPosition`     | object | No       | —       | Specifies a position in an album.                                                                   |
| `newEnrichmentItem` | object | No       | —       | A new enrichment item to be added to an app created album, used by the `albums.addEnrichment` call. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Required. Identifier of the app created album where the enrichment is to be added."
      },
      "albumPosition": {
        "type": "object",
        "description": "Specifies a position in an album.",
        "properties": {
          "position": {
            "type": "string",
            "description": "Type of position, for a media or enrichment item.",
            "enum": [
              "POSITION_TYPE_UNSPECIFIED",
              "FIRST_IN_ALBUM",
              "LAST_IN_ALBUM",
              "AFTER_MEDIA_ITEM",
              "AFTER_ENRICHMENT_ITEM"
            ]
          },
          "relativeMediaItemId": {
            "type": "string",
            "description": "The media item to which the position is relative to. Only used when position type is AFTER_MEDIA_ITEM."
          },
          "relativeEnrichmentItemId": {
            "type": "string",
            "description": "The enrichment item to which the position is relative to. Only used when position type is AFTER_ENRICHMENT_ITEM."
          }
        }
      },
      "newEnrichmentItem": {
        "type": "object",
        "description": "A new enrichment item to be added to an app created album, used by the `albums.addEnrichment` call.",
        "properties": {
          "textEnrichment": {
            "type": "object",
            "description": "An enrichment containing text."
          },
          "locationEnrichment": {
            "type": "object",
            "description": "An enrichment containing a single location."
          },
          "mapEnrichment": {
            "type": "object",
            "description": "An enrichment containing a map, showing origin and destination locations."
          }
        }
      }
    },
    "required": [
      "PCID",
      "albumId"
    ]
  }
  ```
</Expandable>

***

## google-photos\_batch\_add\_media\_items\_albums

Adds one or more app created media items in a user's Google Photos library to an app created album. The media items and albums must have been created by the developer via the API. Media items are added to the end of the album. If multiple media items are given, they are added in the order specified in this call. Each album can contain up to 20,000 media items. Partial success is not supported. The entire request will fail if an invalid media item or album is specified.

**Parameters:**

| Parameter      | Type      | Required | Default | Description                                                                                                                 |
| -------------- | --------- | -------- | ------- | --------------------------------------------------------------------------------------------------------------------------- |
| `albumId`      | string    | Yes      | —       | Required. Identifier of the Album that the media items are added to.                                                        |
| `mediaItemIds` | string\[] | No       | —       | Required. Identifiers of the MediaItems to be added. The maximum number of media items that can be added in one call is 50. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Required. Identifier of the Album that the media items are added to."
      },
      "mediaItemIds": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "Required. Identifiers of the MediaItems to be added. The maximum number of media items that can be added in one call is 50."
      }
    },
    "required": [
      "PCID",
      "albumId"
    ]
  }
  ```
</Expandable>

***

## google-photos\_batch\_create\_media\_items

Creates one or more media items in a user's Google Photos library. This is the second step for creating a media item. For details regarding Step 1, uploading the raw bytes to a Google Server, see Uploading media. This call adds the media item to the library. If an app created album `id` is specified, the call adds the media item to the album too. Each album can contain up to 20,000 media items. By default, the media item will be added to the end of the library or album. If an album `id` and position are both defined, the media item is added to the album at the specified position. If the call contains multiple media items, they're added at the specified position.

**Parameters:**

| Parameter       | Type      | Required | Default | Description                                                                                                                               |
| --------------- | --------- | -------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------- |
| `albumId`       | string    | No       | —       | Identifier of the album where the media items are added. The media items are also added to the user's library. This is an optional field. |
| `albumPosition` | object    | No       | —       | Specifies a position in an album.                                                                                                         |
| `newMediaItems` | object\[] | No       | —       | Required. List of media items to be created. Maximum 50 media items per call.                                                             |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Identifier of the album where the media items are added. The media items are also added to the user's library. This is an optional field."
      },
      "albumPosition": {
        "type": "object",
        "description": "Specifies a position in an album.",
        "properties": {
          "position": {
            "type": "string",
            "description": "Type of position, for a media or enrichment item.",
            "enum": [
              "POSITION_TYPE_UNSPECIFIED",
              "FIRST_IN_ALBUM",
              "LAST_IN_ALBUM",
              "AFTER_MEDIA_ITEM",
              "AFTER_ENRICHMENT_ITEM"
            ]
          },
          "relativeMediaItemId": {
            "type": "string",
            "description": "The media item to which the position is relative to. Only used when position type is AFTER_MEDIA_ITEM."
          },
          "relativeEnrichmentItemId": {
            "type": "string",
            "description": "The enrichment item to which the position is relative to. Only used when position type is AFTER_ENRICHMENT_ITEM."
          }
        }
      },
      "newMediaItems": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "description": {
              "type": "string",
              "description": "Description of the media item. This is shown to the user in the item's info section in the Google Photos app. Must be shorter than 1000 characters. Only include text written by users. Descriptions should add context and help users understand media. Do not include any auto-generated strings such as filenames, tags, and other metadata."
            },
            "simpleMediaItem": {
              "type": "object",
              "description": "A simple media item to be created in Google Photos via an upload token."
            }
          }
        },
        "description": "Required. List of media items to be created. Maximum 50 media items per call."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_batch\_get\_media\_items

Returns the list of app created media items for the specified media item identifiers. Items are returned in the same order as the supplied identifiers.

**Parameters:**

| Parameter      | Type      | Required | Default | Description                                                                                                                                                                                     |
| -------------- | --------- | -------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `mediaItemIds` | string\[] | Yes      | —       | Required. Identifiers of the media items to be requested. Must not contain repeated identifiers and cannot be empty. The maximum number of media items that can be retrieved in one call is 50. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "mediaItemIds": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "Required. Identifiers of the media items to be requested. Must not contain repeated identifiers and cannot be empty. The maximum number of media items that can be retrieved in one call is 50."
      }
    },
    "required": [
      "PCID",
      "mediaItemIds"
    ]
  }
  ```
</Expandable>

***

## google-photos\_batch\_remove\_media\_items\_albums

Removes one or more app created media items from a specified app created album. The media items and the album must have been created by the developer via the API. Partial success is not supported. The entire request will fail and no action will be performed on the album if an invalid media item or album is specified.

**Parameters:**

| Parameter      | Type      | Required | Default | Description                                                                                                                                                                                |
| -------------- | --------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `albumId`      | string    | Yes      | —       | Required. Identifier of the Album that the media items are to be removed from.                                                                                                             |
| `mediaItemIds` | string\[] | No       | —       | Required. Identifiers of the MediaItems to be removed. Must not contain repeated identifiers and cannot be empty. The maximum number of media items that can be removed in one call is 50. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Required. Identifier of the Album that the media items are to be removed from."
      },
      "mediaItemIds": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "Required. Identifiers of the MediaItems to be removed. Must not contain repeated identifiers and cannot be empty. The maximum number of media items that can be removed in one call is 50."
      }
    },
    "required": [
      "PCID",
      "albumId"
    ]
  }
  ```
</Expandable>

***

## google-photos\_create\_albums

Creates an album in a user's Google Photos library.

**Parameters:**

| Parameter | Type   | Required | Default | Description                                                                                                                                                                    |
| --------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `album`   | object | No       | —       | Representation of an album in Google Photos. Albums are containers for media items. If an album has been shared by the application, it contains an extra `shareInfo` property. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "album": {
        "type": "object",
        "description": "Representation of an album in Google Photos. Albums are containers for media items. If an album has been shared by the application, it contains an extra `shareInfo` property.",
        "properties": {
          "id": {
            "type": "string",
            "description": "Identifier for the album. This is a persistent identifier that can be used between sessions to identify this album."
          },
          "title": {
            "type": "string",
            "description": "Name of the album displayed to the user in their Google Photos account. This string shouldn't be more than 500 characters."
          },
          "productUrl": {
            "type": "string",
            "description": "[Output only] Google Photos URL for the album. The user needs to be signed in to their Google Photos account to access this link."
          },
          "isWriteable": {
            "type": "boolean",
            "description": "[Output only] True if you can create media items in this album. This field is based on the scopes granted and permissions of the album. If the scopes are changed or permissions of the album are changed, this field is updated."
          },
          "shareInfo": {
            "type": "object",
            "description": "Information about albums that are shared. This information is only included if you created the album, it is shared and you have the sharing scope."
          },
          "mediaItemsCount": {
            "type": "string",
            "description": "[Output only] The number of media items in the album."
          },
          "coverPhotoBaseUrl": {
            "type": "string",
            "description": "[Output only] A URL to the cover photo's bytes. This shouldn't be used as is. Parameters should be appended to this URL before use. See the [developer documentation](https://developers.google.com/photos/library/guides/access-media-items#base-urls) for a complete list of supported parameters. For example, `'=w2048-h1024'` sets the dimensions of the cover photo to have a width of 2048 px and height of 1024 px."
          },
          "coverPhotoMediaItemId": {
            "type": "string",
            "description": "Identifier for the media item associated with the cover photo."
          }
        }
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_get\_albums

Returns the app created album based on the specified `albumId`. The `albumId` must be the ID of an album created by your app.

**Parameters:**

| Parameter | Type   | Required | Default | Description                                        |
| --------- | ------ | -------- | ------- | -------------------------------------------------- |
| `albumId` | string | Yes      | —       | Required. Identifier of the album to be requested. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Required. Identifier of the album to be requested."
      }
    },
    "required": [
      "PCID",
      "albumId"
    ]
  }
  ```
</Expandable>

***

## google-photos\_get\_media\_items

Returns the app created media item for the specified media item identifier.

**Parameters:**

| Parameter     | Type   | Required | Default | Description                                             |
| ------------- | ------ | -------- | ------- | ------------------------------------------------------- |
| `mediaItemId` | string | Yes      | —       | Required. Identifier of the media item to be requested. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "mediaItemId": {
        "type": "string",
        "description": "Required. Identifier of the media item to be requested."
      }
    },
    "required": [
      "PCID",
      "mediaItemId"
    ]
  }
  ```
</Expandable>

***

## google-photos\_get\_shared\_albums

*Beginning March 31, 2025, this method will no longer work. Some or all of the scopes previously used for this method are being removed. Please see Photos APIs updates for more details.* Returns the album based on the specified `shareToken`.

**Parameters:**

| Parameter    | Type   | Required | Default | Description                                         |
| ------------ | ------ | -------- | ------- | --------------------------------------------------- |
| `shareToken` | string | Yes      | —       | Required. Share token of the album to be requested. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "shareToken": {
        "type": "string",
        "description": "Required. Share token of the album to be requested."
      }
    },
    "required": [
      "PCID",
      "shareToken"
    ]
  }
  ```
</Expandable>

***

## google-photos\_join\_shared\_albums

Joins a shared album on behalf of the Google Photos user.

**Parameters:**

| Parameter    | Type   | Required | Default | Description                                                     |
| ------------ | ------ | -------- | ------- | --------------------------------------------------------------- |
| `shareToken` | string | No       | —       | Required. Token to join the shared album on behalf of the user. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "shareToken": {
        "type": "string",
        "description": "Required. Token to join the shared album on behalf of the user."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_leave\_shared\_albums

Leaves a previously-joined shared album on behalf of the Google Photos user. The user must not own this album.

**Parameters:**

| Parameter    | Type   | Required | Default | Description                                                      |
| ------------ | ------ | -------- | ------- | ---------------------------------------------------------------- |
| `shareToken` | string | No       | —       | Required. Token to leave the shared album on behalf of the user. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "shareToken": {
        "type": "string",
        "description": "Required. Token to leave the shared album on behalf of the user."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_list\_albums

Lists all albums created by your app.

**Parameters:**

| Parameter                  | Type    | Required | Default | Description                                                                                                                                                                                                                                             |
| -------------------------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `pageSize`                 | integer | No       | —       | Maximum number of albums to return in the response. Fewer albums might be returned than the specified number. The default `pageSize` is 20, the maximum is 50.                                                                                          |
| `pageToken`                | string  | No       | —       | A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `listAlbums` request. |
| `excludeNonAppCreatedData` | boolean | No       | —       | If set, the results exclude media items that were not created by this app. Defaults to false (all albums are returned). This field is ignored if the photoslibrary.readonly.appcreateddata scope is used.                                               |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "pageSize": {
        "type": "integer",
        "description": "Maximum number of albums to return in the response. Fewer albums might be returned than the specified number. The default `pageSize` is 20, the maximum is 50."
      },
      "pageToken": {
        "type": "string",
        "description": "A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `listAlbums` request."
      },
      "excludeNonAppCreatedData": {
        "type": "boolean",
        "description": "If set, the results exclude media items that were not created by this app. Defaults to false (all albums are returned). This field is ignored if the photoslibrary.readonly.appcreateddata scope is used."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_list\_media\_items

List all media items created by your app from a user's Google Photos library.

**Parameters:**

| Parameter   | Type    | Required | Default | Description                                                                                                                                                                                                                                                 |
| ----------- | ------- | -------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `pageSize`  | integer | No       | —       | Maximum number of media items to return in the response. Fewer media items might be returned than the specified number. The default `pageSize` is 25, the maximum is 100.                                                                                   |
| `pageToken` | string  | No       | —       | A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `listMediaItems` request. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "pageSize": {
        "type": "integer",
        "description": "Maximum number of media items to return in the response. Fewer media items might be returned than the specified number. The default `pageSize` is 25, the maximum is 100."
      },
      "pageToken": {
        "type": "string",
        "description": "A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `listMediaItems` request."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_list\_shared\_albums

Lists all shared albums available in the Sharing tab of the user's Google Photos app.

**Parameters:**

| Parameter                  | Type    | Required | Default | Description                                                                                                                                                                                                                                                   |
| -------------------------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `pageSize`                 | integer | No       | —       | Maximum number of albums to return in the response. Fewer albums might be returned than the specified number. The default `pageSize` is 20, the maximum is 50.                                                                                                |
| `pageToken`                | string  | No       | —       | A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `listSharedAlbums` request. |
| `excludeNonAppCreatedData` | boolean | No       | —       | If set, the results exclude media items that were not created by this app. Defaults to false (all albums are returned). This field is ignored if the photoslibrary.readonly.appcreateddata scope is used.                                                     |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "pageSize": {
        "type": "integer",
        "description": "Maximum number of albums to return in the response. Fewer albums might be returned than the specified number. The default `pageSize` is 20, the maximum is 50."
      },
      "pageToken": {
        "type": "string",
        "description": "A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `listSharedAlbums` request."
      },
      "excludeNonAppCreatedData": {
        "type": "boolean",
        "description": "If set, the results exclude media items that were not created by this app. Defaults to false (all albums are returned). This field is ignored if the photoslibrary.readonly.appcreateddata scope is used."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_patch\_albums

Update the app created album with the specified `id`. Only the `id`, `title` and `cover_photo_media_item_id` fields of the album are read. The album must have been created by the developer via the API.

**Parameters:**

| Parameter               | Type    | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                                                  |
| ----------------------- | ------- | -------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `id`                    | string  | Yes      | —       | Identifier for the album. This is a persistent identifier that can be used between sessions to identify this album.                                                                                                                                                                                                                                                                                                          |
| `updateMask`            | string  | Yes      | —       | Required. Indicate what fields in the provided album to update. The only valid values are `title` and `cover_photo_media_item_id`.                                                                                                                                                                                                                                                                                           |
| `coverPhotoBaseUrl`     | string  | No       | —       | \[Output only] A URL to the cover photo's bytes. This shouldn't be used as is. Parameters should be appended to this URL before use. See the [developer documentation](https://developers.google.com/photos/library/guides/access-media-items#base-urls) for a complete list of supported parameters. For example, `'=w2048-h1024'` sets the dimensions of the cover photo to have a width of 2048 px and height of 1024 px. |
| `coverPhotoMediaItemId` | string  | No       | —       | Identifier for the media item associated with the cover photo.                                                                                                                                                                                                                                                                                                                                                               |
| `isWriteable`           | boolean | No       | —       | \[Output only] True if you can create media items in this album. This field is based on the scopes granted and permissions of the album. If the scopes are changed or permissions of the album are changed, this field is updated.                                                                                                                                                                                           |
| `mediaItemsCount`       | string  | No       | —       | \[Output only] The number of media items in the album.                                                                                                                                                                                                                                                                                                                                                                       |
| `productUrl`            | string  | No       | —       | \[Output only] Google Photos URL for the album. The user needs to be signed in to their Google Photos account to access this link.                                                                                                                                                                                                                                                                                           |
| `shareInfo`             | object  | No       | —       | Information about albums that are shared. This information is only included if you created the album, it is shared and you have the sharing scope.                                                                                                                                                                                                                                                                           |
| `title`                 | string  | No       | —       | Name of the album displayed to the user in their Google Photos account. This string shouldn't be more than 500 characters.                                                                                                                                                                                                                                                                                                   |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "id": {
        "type": "string",
        "description": "Identifier for the album. This is a persistent identifier that can be used between sessions to identify this album."
      },
      "updateMask": {
        "type": "string",
        "description": "Required. Indicate what fields in the provided album to update. The only valid values are `title` and `cover_photo_media_item_id`."
      },
      "coverPhotoBaseUrl": {
        "type": "string",
        "description": "[Output only] A URL to the cover photo's bytes. This shouldn't be used as is. Parameters should be appended to this URL before use. See the [developer documentation](https://developers.google.com/photos/library/guides/access-media-items#base-urls) for a complete list of supported parameters. For example, `'=w2048-h1024'` sets the dimensions of the cover photo to have a width of 2048 px and height of 1024 px."
      },
      "coverPhotoMediaItemId": {
        "type": "string",
        "description": "Identifier for the media item associated with the cover photo."
      },
      "isWriteable": {
        "type": "boolean",
        "description": "[Output only] True if you can create media items in this album. This field is based on the scopes granted and permissions of the album. If the scopes are changed or permissions of the album are changed, this field is updated."
      },
      "mediaItemsCount": {
        "type": "string",
        "description": "[Output only] The number of media items in the album."
      },
      "productUrl": {
        "type": "string",
        "description": "[Output only] Google Photos URL for the album. The user needs to be signed in to their Google Photos account to access this link."
      },
      "shareInfo": {
        "type": "object",
        "description": "Information about albums that are shared. This information is only included if you created the album, it is shared and you have the sharing scope.",
        "properties": {
          "sharedAlbumOptions": {
            "type": "object",
            "description": "Options that control the sharing of an album."
          },
          "shareableUrl": {
            "type": "string",
            "description": "A link to the shared Google Photos album. Anyone with the link can view the contents of the album, so it should be treated with care. The `shareableUrl` parameter is only returned if the album has link sharing turned on. If a user is already joined to an album that isn't link-shared, they can use the album's [`productUrl`](https://developers.google.com/photos/library/reference/rest/v1/albums#Album) to access it instead. A `shareableUrl` is invalidated if the owner turns off link sharing in the Google Photos app, or if the album is unshared."
          },
          "shareToken": {
            "type": "string",
            "description": "A token that is used to join, leave, or retrieve the details of a shared album on behalf of a user who isn't the owner. A `shareToken` is invalidated if the owner turns off link sharing in the Google Photos app, or if the album is unshared."
          },
          "isJoined": {
            "type": "boolean",
            "description": "True if the user is joined to the album. This is always true for the owner of the album."
          },
          "isOwned": {
            "type": "boolean",
            "description": "True if the user owns the album."
          },
          "isJoinable": {
            "type": "boolean",
            "description": "True if the album can be joined by users."
          }
        }
      },
      "title": {
        "type": "string",
        "description": "Name of the album displayed to the user in their Google Photos account. This string shouldn't be more than 500 characters."
      }
    },
    "required": [
      "PCID",
      "id",
      "updateMask"
    ]
  }
  ```
</Expandable>

***

## google-photos\_patch\_media\_items

Update the app created media item with the specified `id`. Only the `id` and `description` fields of the media item are read. The media item must have been created by the developer via the API.

**Parameters:**

| Parameter         | Type   | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                                                 |
| ----------------- | ------ | -------- | ------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `id`              | string | Yes      | —       | Identifier for the media item. This is a persistent identifier that can be used between sessions to identify this media item.                                                                                                                                                                                                                                                                                               |
| `updateMask`      | string | Yes      | —       | Required. Indicate what fields in the provided media item to update. The only valid value is `description`.                                                                                                                                                                                                                                                                                                                 |
| `baseUrl`         | string | No       | —       | A URL to the media item's bytes. This shouldn't be used as is. Parameters should be appended to this URL before use. See the [developer documentation](https://developers.google.com/photos/library/guides/access-media-items#base-urls) for a complete list of supported parameters. For example, `'=w2048-h1024'` will set the dimensions of a media item of type photo to have a width of 2048 px and height of 1024 px. |
| `contributorInfo` | object | No       | —       | Information about the user who added the media item. Note that this information is included only if the media item is within a shared album created by your app and you have the sharing scope.                                                                                                                                                                                                                             |
| `description`     | string | No       | —       | Description of the media item. This is shown to the user in the item's info section in the Google Photos app. Must be shorter than 1000 characters. Only include text written by users. Descriptions should add context and help users understand media. Do not include any auto-generated strings such as filenames, tags, and other metadata.                                                                             |
| `filename`        | string | No       | —       | Filename of the media item. This is shown to the user in the item's info section in the Google Photos app.                                                                                                                                                                                                                                                                                                                  |
| `mediaMetadata`   | object | No       | —       | Metadata for a media item.                                                                                                                                                                                                                                                                                                                                                                                                  |
| `mimeType`        | string | No       | —       | MIME type of the media item. For example, `image/jpeg`.                                                                                                                                                                                                                                                                                                                                                                     |
| `productUrl`      | string | No       | —       | Google Photos URL for the media item. This link is available to the user only if they're signed in. When retrieved from an album search, the URL points to the item inside the album.                                                                                                                                                                                                                                       |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "id": {
        "type": "string",
        "description": "Identifier for the media item. This is a persistent identifier that can be used between sessions to identify this media item."
      },
      "updateMask": {
        "type": "string",
        "description": "Required. Indicate what fields in the provided media item to update. The only valid value is `description`."
      },
      "baseUrl": {
        "type": "string",
        "description": "A URL to the media item's bytes. This shouldn't be used as is. Parameters should be appended to this URL before use. See the [developer documentation](https://developers.google.com/photos/library/guides/access-media-items#base-urls) for a complete list of supported parameters. For example, `'=w2048-h1024'` will set the dimensions of a media item of type photo to have a width of 2048 px and height of 1024 px."
      },
      "contributorInfo": {
        "type": "object",
        "description": "Information about the user who added the media item. Note that this information is included only if the media item is within a shared album created by your app and you have the sharing scope.",
        "properties": {
          "profilePictureBaseUrl": {
            "type": "string",
            "description": "URL to the profile picture of the contributor."
          },
          "displayName": {
            "type": "string",
            "description": "Display name of the contributor."
          }
        }
      },
      "description": {
        "type": "string",
        "description": "Description of the media item. This is shown to the user in the item's info section in the Google Photos app. Must be shorter than 1000 characters. Only include text written by users. Descriptions should add context and help users understand media. Do not include any auto-generated strings such as filenames, tags, and other metadata."
      },
      "filename": {
        "type": "string",
        "description": "Filename of the media item. This is shown to the user in the item's info section in the Google Photos app."
      },
      "mediaMetadata": {
        "type": "object",
        "description": "Metadata for a media item.",
        "properties": {
          "creationTime": {
            "type": "string",
            "description": "Time when the media item was first created (not when it was uploaded to Google Photos)."
          },
          "width": {
            "type": "string",
            "description": "Original width (in pixels) of the media item."
          },
          "height": {
            "type": "string",
            "description": "Original height (in pixels) of the media item."
          },
          "photo": {
            "type": "object",
            "description": "Metadata that is specific to a photo, such as, ISO, focal length and exposure time. Some of these fields may be null or not included."
          },
          "video": {
            "type": "object",
            "description": "Metadata that is specific to a video, for example, fps and processing status. Some of these fields may be null or not included."
          }
        }
      },
      "mimeType": {
        "type": "string",
        "description": "MIME type of the media item. For example, `image/jpeg`."
      },
      "productUrl": {
        "type": "string",
        "description": "Google Photos URL for the media item. This link is available to the user only if they're signed in. When retrieved from an album search, the URL points to the item inside the album."
      }
    },
    "required": [
      "PCID",
      "id",
      "updateMask"
    ]
  }
  ```
</Expandable>

***

## google-photos\_search\_media\_items

Searches for app created media items in a user's Google Photos library. Only media items and ablums created by your app are returned. If no filters are set, then all app created media items in the user's library are returned. If an app created album is set, all media items in the specified album are returned. If filters are specified, app created media items that match the filters from the user's library are listed. If you set both the album and the filters, the request results in an error.

**Parameters:**

| Parameter   | Type    | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| ----------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `albumId`   | string  | No       | —       | Identifier of an album. If populated, lists all media items in specified album. Can't set in conjunction with any filters.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `filters`   | object  | No       | —       | Filters that can be applied to a media item search. If multiple filter options are specified, they're treated as AND with each other.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| `orderBy`   | string  | No       | —       | An optional field to specify the sort order of the search results. The `orderBy` field only works when a dateFilter is used. When this field is not specified, results are displayed newest first, oldest last by their creationTime. Providing `MediaMetadata.creation_time` displays search results in the opposite order, oldest first then newest last. To display results newest first then oldest last, include the `desc` argument as follows: `MediaMetadata.creation_time desc`. The only additional filters that can be used with this parameter are includeArchivedMedia and excludeNonAppCreatedData. No other filters are supported. |
| `pageSize`  | integer | No       | —       | Maximum number of media items to return in the response. Fewer media items might be returned than the specified number. The default `pageSize` is 25, the maximum is 100.                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `pageToken` | string  | No       | —       | A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `searchMediaItems` request.                                                                                                                                                                                                                                                                                                                                                                                     |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Identifier of an album. If populated, lists all media items in specified album. Can't set in conjunction with any filters."
      },
      "filters": {
        "type": "object",
        "description": "Filters that can be applied to a media item search. If multiple filter options are specified, they're treated as AND with each other.",
        "properties": {
          "dateFilter": {
            "type": "object",
            "description": "This filter defines the allowed dates or date ranges for the media returned. It's possible to pick a set of specific dates and a set of date ranges. Media items uploaded without metadata specifying the date the media item was captured will not be returned in queries using date filters. Google Photos server upload time is not used as a fallback in this case."
          },
          "contentFilter": {
            "type": "object",
            "description": "This filter allows you to return media items based on the content type. It's possible to specify a list of categories to include, and/or a list of categories to exclude. Within each list, the categories are combined with an OR. The content filter `includedContentCategories`: [c1, c2, c3] would get media items that contain (c1 OR c2 OR c3). The content filter `excludedContentCategories`: [c1, c2, c3] would NOT get media items that contain (c1 OR c2 OR c3). You can also include some categories while excluding others, as in this example: `includedContentCategories`: [c1, c2], `excludedContentCategories`: [c3, c4] The previous example would get media items that contain (c1 OR c2) AND NOT (c3 OR c4). A category that appears in `includedContentategories` must not appear in `excludedContentCategories`."
          },
          "mediaTypeFilter": {
            "type": "object",
            "description": "This filter defines the type of media items to be returned, for example, videos or photos. Only one media type is supported."
          },
          "featureFilter": {
            "type": "object",
            "description": "This filter defines the features that the media items should have."
          },
          "includeArchivedMedia": {
            "type": "boolean",
            "description": "If set, the results include media items that the user has archived. Defaults to false (archived media items aren't included)."
          },
          "excludeNonAppCreatedData": {
            "type": "boolean",
            "description": "If set, the results exclude media items that were not created by this app. Defaults to false (all media items are returned). This field is ignored if the photoslibrary.readonly.appcreateddata scope is used."
          }
        }
      },
      "orderBy": {
        "type": "string",
        "description": "An optional field to specify the sort order of the search results. The `orderBy` field only works when a dateFilter is used. When this field is not specified, results are displayed newest first, oldest last by their creationTime. Providing `MediaMetadata.creation_time` displays search results in the opposite order, oldest first then newest last. To display results newest first then oldest last, include the `desc` argument as follows: `MediaMetadata.creation_time desc`. The only additional filters that can be used with this parameter are includeArchivedMedia and excludeNonAppCreatedData. No other filters are supported."
      },
      "pageSize": {
        "type": "integer",
        "description": "Maximum number of media items to return in the response. Fewer media items might be returned than the specified number. The default `pageSize` is 25, the maximum is 100."
      },
      "pageToken": {
        "type": "string",
        "description": "A continuation token to get the next page of the results. Adding this to the request returns the rows after the `pageToken`. The `pageToken` should be the value returned in the `nextPageToken` parameter in the response to the `searchMediaItems` request."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## google-photos\_share\_albums

Marks an album as shared and accessible to other users. This action can only be performed on albums which were created by the developer via the API.

**Parameters:**

| Parameter            | Type   | Required | Default | Description                                                                                                      |
| -------------------- | ------ | -------- | ------- | ---------------------------------------------------------------------------------------------------------------- |
| `albumId`            | string | Yes      | —       | Required. Identifier of the album to be shared. This `albumId` must belong to an album created by the developer. |
| `sharedAlbumOptions` | object | No       | —       | Options that control the sharing of an album.                                                                    |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Required. Identifier of the album to be shared. This `albumId` must belong to an album created by the developer."
      },
      "sharedAlbumOptions": {
        "type": "object",
        "description": "Options that control the sharing of an album.",
        "properties": {
          "isCollaborative": {
            "type": "boolean",
            "description": "True if the shared album allows collaborators (users who have joined the album) to add media items to it. Defaults to false."
          },
          "isCommentable": {
            "type": "boolean",
            "description": "True if the shared album allows collaborators (users who have joined the album) to add comments to the album. Defaults to false."
          }
        }
      }
    },
    "required": [
      "PCID",
      "albumId"
    ]
  }
  ```
</Expandable>

***

## google-photos\_unshare\_albums

Marks a previously shared album as private. This means that the album is no longer shared and all the non-owners will lose access to the album. All non-owner content will be removed from the album. If a non-owner has previously added the album to their library, they will retain all photos in their library. This action can only be performed on albums which were created by the developer via the API.

**Parameters:**

| Parameter | Type   | Required | Default | Description                                                                                                       |
| --------- | ------ | -------- | ------- | ----------------------------------------------------------------------------------------------------------------- |
| `albumId` | string | Yes      | —       | Required. Identifier of the album to be unshared. This album id must belong to an album created by the developer. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "albumId": {
        "type": "string",
        "description": "Required. Identifier of the album to be unshared. This album id must belong to an album created by the developer."
      }
    },
    "required": [
      "PCID",
      "albumId"
    ]
  }
  ```
</Expandable>
