---
title: "Record a subscriber state by contact ID"
method: POST
path: "/marketing/marketing-events/2026-09/events/{externalEventId}/{subscriberState}/upsert"
tags: ["Subscriber State Changes"]
---

# Record a subscriber state by contact ID

`POST /marketing/marketing-events/2026-09/events/{externalEventId}/{subscriberState}/upsert`

## Request

- Base URL: `https://api.hubapi.com`
- URL: `https://api.hubapi.com/marketing/marketing-events/2026-09/events/{externalEventId}/{subscriberState}/upsert`
- Auth: OAuth 2
  - Authorization code: `https://app.hubspot.com/oauth/authorize`
  - Token URL: `https://api.hubapi.com/oauth/v1/token` scopes: `crm.objects.marketing_events.write`

Record a subscriber state between multiple HubSpot contacts and a marketing event, using HubSpot contact IDs. Note that the contact must already exist in HubSpot; a contact will not be created.

## Path parameters

- `externalEventId` string, required
- `subscriberState` string, required

## Query parameters

- `externalAccountId` string, required

## Request body

- BatchInputMarketingEventSubscriber
  - `inputs` MarketingEventSubscriber[], required: List of HubSpot contacts to subscribe to the marketing event
    - `interactionDateTime` integer, required: Timestamp in milliseconds at which the contact subscribed to the event.
    - `properties` object, required: The key-value set of the properties of the contact
    - `vid` integer, required: The ID of the contact in HubSpot

## Response `default`

An error occurred.

## Changes

- **2026-09-03** (2026-09) `e62ad9a49a20`: 2 info
  - the endpoint scheme security `private_apps` was removed from the API
  - the `inputs/items/vid` request property format was generalized from `int32` to `int64`

[Operation history](https://skmtc.dev/hubspot/apis/marketing-marketing-events/changes/marketing/marketing-events/2026-09/events/:externalEventId/:subscriberState/upsert/post.md)

---

[API](https://skmtc.dev/hubspot/apis/marketing-marketing-events.md) - [All operations](https://skmtc.dev/hubspot/apis/marketing-marketing-events/llms.txt) - [OpenAPI document](https://skmtc.dev/hubspot/apis/marketing-marketing-events/revisions/3afcf69ad1b4?raw)
