# Firestore Import (`apify/firestore-import`) Actor

Seamlessly import data from Apify datasets into Firebase Firestore database. This integration allows full control over document IDs, conflict resolution (overwrite, merge, skip), and data transformation using a custom JavaScript function.

- **URL**: https://apify.com/apify/firestore-import.md
- **Developed by:** [Apify](https://apify.com/apify) (Apify)
- **Categories:** Automation, Integrations, Open source
- **Stats:** 11 total users, 3 monthly users, 100.0% runs succeeded, 5 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-usage

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Firestore Import

The Firestore Import is Apify integration [Actor](https://docs.apify.com/platform/actors#what-is-an-actor) that import data into [Firebase Firestore](https://firebase.google.com/docs/firestore)
(NoSQL cloud database build on Google Cloud infrastructure) from [Apify dataset](https://docs.apify.com/platform/storage/dataset).
It allows you to configure various options, such as the target collection, handling conflicts in data,
and transforming the dataset item before importing it into Firestore.

### Features
The Firestore Import Actor takes a dataset, applies transformations, and imports the data into a Firestore database.
This Actor is highly customizable, you can control how the data are imported such as:
- Selecting Firestore database and collection.
- Automatically generating document IDs or using a field from the dataset for the document ID.
- Handling document conflicts by either overwriting, merging, or skipping documents with existing ID.
- Transforming data before it gets imported using a customizable JavaScript function.
- One dataset item can lead to multiple Firestore inserts/updates.
- Each document can have its own configuration, such as a custom collection or document ID.

### Input

The actor requires several input fields to work correctly. Below is a detailed description of each input field:

| **Field Name**               | **Type**                                          | **Description**                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
|------------------------------|---------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `serviceAccountKey`          | `string` (secret, *required*)                     | Service account key in JSON format.<br/>You can get it from *Firebase Console* -> *Project Settings* -> *Service accounts* -> *Generate new private key*.<br/><br/>Paste the whole JSON string here, don't worry this is [secret input](https://docs.apify.com/platform/actors/development/actor-definition/input-schema/secret-input) which store the value in encrypted form.                                                                                                          |
| `datasetId`                  | `string` (*required*)                             | ID of the Apify dataset to import data from.                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| `collection`                 | `string` (*required*)                             | Firestore collection to import data to. If it doesn't exist, it will be created.<br/><br/>*Note:* you can customize the collection for each record by using the `transformFunction` input. This can be useful when you want to import data to sub-collections.                                                                                                                                                                                                                           |
| `databaseName`               | `string` (*optional*)                             | Name of the Firestore database.<br/>If not provided, the default database (`"(default)"`) will be used.                                                                                                                                                                                                                                                                                                                                                                                  |
| `idField`                    | `string` (*optional*)                             | Field in the dataset item that will be used as a Firestore document ID. It must be `string` or `number`.<br/>If not provided, all documents will be created with a random ID generated by Firestore (it means that value of `documentConflictResolution` is ignored in that case).<br/><br/>This is useful when you want to update existing documents in Firestore.<br/><br/>*Note:* you can customize the ID for each document independently using the `transformFunction` input field. |
| `documentConflictResolution` | `enum`: `overwrite`, `merge`, `skip` (*required*) | How to handle conflicts when importing data to Firestore:<br>  - ***overwrite***: replace existing Firestore documents with the same ID.<br>  - ***merge***: merge data from the dataset items with existing Firestore documents.<br>  - ***skip***: documents with existing IDs will be skipped.<br/><br/>⚠️ Please note that the *skip* resolution has really bad performance on large scale and can't use batch writes (it makes request to Firestore for each document separately).  |
| `transformFunction`          | `string` (javascript, *optional*)                 | Javascript function that transforms each item from the dataset before importing it to Firestore.<br/><br/>The function must return an object (or array of objects) with the `data` key that contains the transformed record and other optional fields. See examples below.                                                                                                                                                                                                               |
| `batchSize`                  | `number` (*optional*)                             | Number of items to import in a single batch. Lower values are safer but slower, see [Firestore limits](https://firebase.google.com/docs/firestore/quotas) (10 MiB batch write). Please note that *skip* conflict resolution does not use batch writes and will always import one item at a time.<br/>Defaults to `500`.                                                                                                                                                                  |


### Transformation Function

The option `transformFunction` input field allows you to transform each dataset item before importing it to Firestore.
The field accepts a JavaScript function that takes one dataset item as a parameter and returns an object (or array of objects) with the following keys:

- `data` (required): transformed document that will be imported to Firestore.
- `id` (optional): custom document ID. If not provided, the `idField` input field will be used to resolve document id or if not provided the document will be created with a random ID generated by Firestore.
- `collection` (optional): custom collection name. If not provided, the `collection` input field will be used.
- `documentConflictResolution` (optional): custom conflict resolution for the document. If not provided, the `documentConflictResolution` input field will be used.

```javascript
(item) => {
    return {
        data: item,                           // transformed document
        id: item.id,                          // custom document ID
        collection: "customCollection",       // custom collection name
        documentConflictResolution: "merge",  // custom conflict resolution
    };
}
````

#### Examples

1. **Simple transformation function:**

   The function below increments the value of the `oldField` by 1 and removes the `unused` field from the dataset item.

   ```javascript
   (item) => {
       item.newField = item.oldField + 1;
       delete item.unused;
       return { data: item };
   }
   ```

2. **Nested objects:**

   The function below transforms the dataset item into a Firestore document with nested objects. It updates the `subdocument.field` field and overwrites the whole `author` sub-document.

   ```javascript
   (item) => {
       return {
           data: {
               title: item.title,
               "subdocument.field": item.name,  // update single field of subdocument
               author: item.author              // overwrite whole subdocument
           },
       };
   }
   ```

3. **Field value functions:**

   The function below demonstrates how to use Firestore `FieldValue` [functions](https://firebase.google.com/docs/reference/node/firebase.firestore.FieldValue).
   It adds new IDs to the existing `ids` array, removes values from the `values` array, increments the `count` field, and deletes the `old` field.

   ```javascript
   (item) => {
       return {
           data: {
               ids: FieldValue.arrayUnion(item.ids),         // add new ids to existing ids array
               values: FieldValue.arrayRemove(item.values),  // remove new values from existing array
               count: FieldValue.increment(item.count),      // increment existing count field by provided value
               old: FieldValue.delete(),                     // removes field
           },
       };
   }
   ```

4. **Data types:**

   The function below demonstrates how to create Firestore data types such as `Timestamp`, `Vector`, `GeoPoint`, and `DocumentReference`.

   ```javascript
   (item) => {
       return {
           data: {
               updatedAt: Timestamp.fromDate(Date.parse(item.date)),          // create Timestamp data type
               vector: FieldValue.VectorValue(item.values),                   // create vector data type
               position: GeoPoint(item.lat, item.lon),                        // create geopoint data type
               reference: DocumentReference("collection", "referenceDocId"),  // create reference type
           },
       };
   }
   ```

5. **Subcollection:**

   The function below demonstrates how to import data to sub-collections.
   It returns an array where the first item is the main document and other items are documents for sub-collection.

   ```javascript
   (item) => {
       const subDocuments = item.items.map((subItem) => ({
           id: subItem.id,
           collection: `records/${item.customId}/items`,
           documentConflictResolution: "skip",
           data: {
               weight: subItem.weight,
               length: subItem.length,
               name: subItem.name,
           },
       }));

       return [
           {
               id: item.customId,
               collection: "records",
               documentConflictResolution: "merge",
               data: {
                   title: item.title,
                   description: item.description,
               },
           },
           ...subDocuments,
       ];
   }
   ```

### Output

The Actor outputs statistics about the import to Key-Value store key `Statistics` with the following structure:

- `imported`: total number of processed Firestore documents (either created, updated or skipped).
- `skipped`: number of skipped Firestore documents.
- `overwritten`: number of overwritten Firestore documents.
- `merged`: number of merged Firestore documents.
- `created`: number of created Firestore documents (counts written document if `documentConflictResolution` is `skip`).
- `failed`: number of failed writes to Firestore documents.
- `itemsProcessed`: total number of processed dataset items (including failed items).
- `itemsFailed`: number of failed dataset items.
- `executionTimeMs`: time in milliseconds it took to import the data.
- `startTime`: timestamp when the import started.
- `endTime`: timestamp when the import ended.

```json
{
  "imported": 59278,
  "skipped": 0,
  "overwritten": 0,
  "merged": 59278,
  "created": 0,
  "failed": 0,
  "itemsProcessed": 1136,
  "itemsFailed": 0,
  "executionTimeMs": 19725,
  "startTime": "2025-02-26T17:56:22.652Z",
  "endTime": "2025-02-26T17:56:42.377Z"
}
```

# Actor input Schema

## `serviceAccountKey` (type: `string`):

Service account key in JSON format. You can get it from *Firebase Console* -> *Project Settings* -> *Service accounts* -> *Generate new private key*. Paste the whole JSON string here.

## `datasetId` (type: `string`):

ID of the Apify dataset to import data from.

## `collection` (type: `string`):

Firestore collection to import data to. If it doesn't exist, it will be created. Note: you can customize the collection for each document using the `transformFunction` input. This can be useful when you want to import data to sub-collections.

## `databaseName` (type: `string`):

Name of the Firestore database. If not provided, the default database (`"(default)"`) will be used.

## `idField` (type: `string`):

Field in the dataset item that will be used as a Firestore document ID. If not provided, all documents will be created with a random ID generated by Firestore (it means that value of `documentConflictResolution` is ignored in that case). This is useful when you want to update existing documents in Firestore. Note: you can customize the ID for each document independently using the `transformFunction` input field.

## `documentConflictResolution` (type: `string`):

How to handle conflicts when importing data to Firestore:

- *overwrite*: replace existing Firestore documents with the same ID.
- *merge*: merge data from the dataset items with existing Firestore documents.
- *skip*: documents with existing IDs will be skipped.
  ⚠️ Please note that the *skip* resolution has really bad performance on large scale and can't use batch writes.

## `transformFunction` (type: `string`):

Function that transforms each item from the dataset before importing it to Firestore. The function must return an object (or array of objects) with the `data` key that contains the transformed document and other optional fields. See README for more details and examples.

## `batchSize` (type: `integer`):

Number of items to import in a single batch. Lower values are safer but slower, see [Firestore limits](https://firebase.google.com/docs/firestore/quotas) (10 MiB batch write). Please note that *skip* conflict resolution does not use batch writes and will always import one item at a time.

## Actor input object example

```json
{
  "databaseName": "(default)",
  "documentConflictResolution": "overwrite",
  "transformFunction": "(data) => {\n    return { data };\n}",
  "batchSize": 500
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "databaseName": "(default)",
    "documentConflictResolution": "overwrite",
    "transformFunction": (data) => {
        return { data };
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("apify/firestore-import").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "databaseName": "(default)",
    "documentConflictResolution": "overwrite",
    "transformFunction": """(data) => {
    return { data };
}""",
}

# Run the Actor and wait for it to finish
run = client.actor("apify/firestore-import").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "databaseName": "(default)",
  "documentConflictResolution": "overwrite",
  "transformFunction": "(data) => {\\n    return { data };\\n}"
}' |
apify call apify/firestore-import --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=apify/firestore-import",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Firestore Import",
        "description": "Seamlessly import data from Apify datasets into Firebase Firestore database. This integration allows full control over document IDs, conflict resolution (overwrite, merge, skip), and data transformation using a custom JavaScript function.",
        "version": "0.0",
        "x-build-id": "HKRKFVHz930F7S76y"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/apify~firestore-import/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-apify-firestore-import",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/apify~firestore-import/runs": {
            "post": {
                "operationId": "runs-sync-apify-firestore-import",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/apify~firestore-import/run-sync": {
            "post": {
                "operationId": "run-sync-apify-firestore-import",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "serviceAccountKey",
                    "collection",
                    "datasetId",
                    "databaseName",
                    "documentConflictResolution",
                    "batchSize"
                ],
                "properties": {
                    "serviceAccountKey": {
                        "title": "Service Account Key",
                        "type": "string",
                        "description": "Service account key in JSON format. You can get it from *Firebase Console* -> *Project Settings* -> *Service accounts* -> *Generate new private key*. Paste the whole JSON string here."
                    },
                    "datasetId": {
                        "title": "Dataset ID",
                        "type": "string",
                        "description": "ID of the Apify dataset to import data from."
                    },
                    "collection": {
                        "title": "Collection",
                        "type": "string",
                        "description": "Firestore collection to import data to. If it doesn't exist, it will be created. Note: you can customize the collection for each document using the `transformFunction` input. This can be useful when you want to import data to sub-collections."
                    },
                    "databaseName": {
                        "title": "Database Name",
                        "type": "string",
                        "description": "Name of the Firestore database. If not provided, the default database (`\"(default)\"`) will be used.",
                        "default": "(default)"
                    },
                    "idField": {
                        "title": "ID Field",
                        "type": "string",
                        "description": "Field in the dataset item that will be used as a Firestore document ID. If not provided, all documents will be created with a random ID generated by Firestore (it means that value of `documentConflictResolution` is ignored in that case). This is useful when you want to update existing documents in Firestore. Note: you can customize the ID for each document independently using the `transformFunction` input field."
                    },
                    "documentConflictResolution": {
                        "title": "Document Conflict Resolution",
                        "enum": [
                            "overwrite",
                            "merge",
                            "skip"
                        ],
                        "type": "string",
                        "description": "How to handle conflicts when importing data to Firestore:\n- *overwrite*: replace existing Firestore documents with the same ID.\n- *merge*: merge data from the dataset items with existing Firestore documents.\n- *skip*: documents with existing IDs will be skipped.\n⚠️ Please note that the *skip* resolution has really bad performance on large scale and can't use batch writes.",
                        "default": "overwrite"
                    },
                    "transformFunction": {
                        "title": "Transform Function",
                        "type": "string",
                        "description": "Function that transforms each item from the dataset before importing it to Firestore. The function must return an object (or array of objects) with the `data` key that contains the transformed document and other optional fields. See README for more details and examples."
                    },
                    "batchSize": {
                        "title": "Batch Size",
                        "type": "integer",
                        "description": "Number of items to import in a single batch. Lower values are safer but slower, see [Firestore limits](https://firebase.google.com/docs/firestore/quotas) (10 MiB batch write). Please note that *skip* conflict resolution does not use batch writes and will always import one item at a time.",
                        "default": 500
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
