Loading...

Get All Objects

Description

This API allows you to get all the objects stored in a bucket. The Bucket is referred by its unique bucket name.

Request Details

Request URL

GET

{api-domain}/baas/v1/project/{project_id}/bucket/objects

copy

project_id
Numerical
The unique ID of the project

Query Parameters

bucket_name Alphanumeric
mandatory
max_keys Number
Optional
Will contain the maximum limit of objects that can be listed by pagination.
continuation_token String
optional
If you sent a continuation_token in the request, it will be shown in the response
prefix String
Optional
This optional value will get the objects that match the prefix value.

Request Headers

Authorization: Zoho-oauthtoken {oauth_token}

Optional Headers

CATALYST-ORG: {org_id}

Environment: Development

Scope

ZohoCatalyst.buckets.objects.READ

Response Details

On successful execution, the response will contain a list of all the objects stored in the required bucket.

Sample Request
copy

curl -X GET https://api.catalyst.zoho.com/baas/v1/project/10108000003823392/buckets/objects?bucket_name=mybucketname&max_keys=10&continuation_token=Sg43ou34rd2bih223oc8csc&prefix=myfolder/ -H “Authorization: Zoho-oauthtoken 1000.910*************************16.2f*************************57”

Sample Response
copy
{
"status": "success",
"data": {
    "key_count": 5,
    "max_keys": 5,
    "truncated": true,
    "next_continuation_token": "n2BjzZo5FvrSQmx7z5LaJk7cvP2Yf2K6AJHw4Sg692TnfwHasUp8DJp8qL24A3TLAGPu8zyEysfjfQpjohEMaej",
    "contents": [
    {
        "key_type": "file",
        "key": "server 96.zip",
        "version_id": "01hh9hnwxw8r88kzzfnkn67grr",
        "size": 3012536,
        "content_type": "application/zip",
        "etag": "e460808d4190b37c472985a1f1d85720",
        "last_modified": "Dec 10, 2023 03:12 PM"
    },
    {
        "key_type": "file",
        "key": "oauthscopes.csv",
        "version_id": "01hh9hnhypzt63fwf5wyk2ef6f",
        "size": 19804,
        "content_type": "text/csv",
        "etag": "354266606189c30c80f336720102ead6",
        "last_modified": "Dec 10, 2023 03:11 PM"
    },
    {
        "key_type": "folder",
        "key": "lib 3",
        "size": 0,
        "last_modified": "Dec 10, 2023 03:11 PM"
    },
    {
        "key_type": "file",
        "key": "funcauthtest-Development (1).zip",
        "version_id": "01hh9hkv8xvetbxnrhx6c7444y",
        "size": 8485,
        "content_type": "application/zip",
        "etag": "5f868df044e91a4c7e26be26b6e93a64",
        "last_modified": "Dec 10, 2023 03:10 PM"
    },
    {
        "key_type": "file",
        "key": "Automl_LZ (1).csv",
        "version_id": "01hh9hkfdf07y8pnpbwtkt8cf7",
        "size": 257,
        "content_type": "text/csv",
        "etag": "223a363af39a49d4b32f6cdf0c569755",
        "last_modified": "Dec 10, 2023 03:10 PM"
    }
    ]
}
}
View more