{"command":{"effect":"write","timeoutSeconds":30,"inputSchema":{"type":"object","description":"Create or update a push token.\n\nThis endpoint can be used to migrate push tokens from another platform to Klaviyo. Please use our mobile SDKs ([iOS](https://github.com/klaviyo/klaviyo-swift-sdk) and [Android](https://github.com/klaviyo/klaviyo-android-sdk)) to create push tokens from users' devices.\n\nThe maximum allowed payload size is 100KB.<br><br>*Rate limits*:<br>Burst: `75/s`<br>Steady: `750/m`\n\n**Scopes:**\n`profiles:write`\n`push-tokens:write`\n\n[OpenAPI Spec](https://raw.githubusercontent.com/klaviyo/openapi/main/openapi/stable/apis/create_push_token.json)","properties":{"headers":{"type":"object","properties":{"revision":{"type":"string","default":"2026-10-15","enum":["2026-10-15"],"description":"API endpoint revision (format: YYYY-MM-DD[.suffix])"}},"required":["revision"],"additionalProperties":false},"body":{"$ref":"#/definitions/PushTokenCreateQuery"}},"required":["headers","body"],"additionalProperties":false,"definitions":{"PushTokenCreateQuery":{"type":"object","properties":{"data":{"$ref":"#/definitions/PushTokenCreateQueryResourceObject"}},"required":["data"]},"PushTokenCreateQueryResourceObject":{"type":"object","properties":{"type":{"$ref":"#/definitions/PushTokenEnum"},"attributes":{"type":"object","properties":{"token":{"description":"A push token from APNS or FCM.","type":"string","examples":["1234567890"]},"platform":{"description":"The platform on which the push token was created.","type":"string","enum":["android","ios"]},"enablement_status":{"description":"This is the enablement status for the individual push token.","type":["string","null"],"default":"AUTHORIZED","enum":["AUTHORIZED","DENIED","NOT_DETERMINED","PROVISIONAL","UNAUTHORIZED"],"examples":["AUTHORIZED"]},"vendor":{"description":"The vendor of the push token.","type":"string","enum":["apns","fcm"],"examples":["apns"]},"background":{"description":"The background state of the push token.","type":["string","null"],"default":"AVAILABLE","enum":["AVAILABLE","DENIED","RESTRICTED"],"examples":["AVAILABLE"]},"device_metadata":{"$ref":"#/definitions/DeviceMetadata"},"profile":{"description":"The profile associated with the push token to create/update","type":"object","properties":{"data":{"$ref":"#/definitions/PushProfileUpsertQueryResourceObject"}},"required":["data"]}},"required":["token","platform","vendor","profile"]}},"required":["type","attributes"]},"PushTokenEnum":{"type":"string","enum":["push-token"]},"DeviceMetadata":{"type":"object","properties":{"device_id":{"description":"Relatively stable ID for the device. Will update on app uninstall and reinstall","type":["string","null"],"examples":["1234567890"]},"klaviyo_sdk":{"description":"The name of the SDK used to create the push token.","type":["string","null"],"enum":["android","flutter","flutter_community","react_native","swift"],"examples":["swift"]},"sdk_version":{"description":"The version of the SDK used to create the push token","type":["string","null"],"examples":["1.0.0"]},"device_model":{"description":"The model of the device","type":["string","null"],"examples":["iPhone12,1"]},"os_name":{"description":"The name of the operating system on the device.","type":["string","null"],"enum":["android","ios","ipados","macos","tvos"],"examples":["ios"]},"os_version":{"description":"The version of the operating system on the device","type":["string","null"],"examples":["14.0"]},"manufacturer":{"description":"The manufacturer of the device","type":["string","null"],"examples":["Apple"]},"app_name":{"description":"The name of the app that created the push token","type":["string","null"],"examples":["Klaviyo"]},"app_version":{"description":"The version of the app that created the push token","type":["string","null"],"examples":["1.0.0"]},"app_build":{"description":"The build of the app that created the push token","type":["string","null"],"examples":["1"]},"app_id":{"description":"The ID of the app that created the push token","type":["string","null"],"examples":["com.klaviyo.app"]},"environment":{"description":"The environment in which the push token was created","type":["string","null"],"enum":["debug","release"],"examples":["release"]}}},"PushProfileUpsertQueryResourceObject":{"type":"object","properties":{"type":{"$ref":"#/definitions/ProfileEnum"},"id":{"description":"Primary key that uniquely identifies this profile. Generated by Klaviyo.","type":["string","null"]},"attributes":{"type":"object","properties":{"phone_number":{"description":"Individual's phone number in E.164 format","type":["string","null"],"examples":["+15005550006"]},"external_id":{"description":"A unique identifier used by customers to associate Klaviyo profiles with profiles in an external system, such as a point-of-sale system. Format varies based on the external system.","type":["string","null"]},"_kx":{"description":"Also known as the `exchange_id`, this is an encrypted identifier used for identifying a\nprofile by Klaviyo's web tracking.\n\nYou can use this field as a filter when retrieving profiles via the Get Profiles endpoint.","type":["string","null"]},"first_name":{"description":"Individual's first name","type":["string","null"],"examples":["Sarah"]},"last_name":{"description":"Individual's last name","type":["string","null"],"examples":["Mason"]},"organization":{"description":"Name of the company or organization within the company for whom the individual works","type":["string","null"],"examples":["Example Corporation"]},"locale":{"description":"The locale of the profile, in the IETF BCP 47 language tag format like (ISO 639-1/2)-(ISO 3166 alpha-2)","type":["string","null"],"examples":["en-US"]},"title":{"description":"Individual's job title","type":["string","null"],"examples":["Regional Manager"]},"image":{"description":"URL pointing to the location of a profile image","type":["string","null"],"examples":["https://images.pexels.com/photos/3760854/pexels-photo-3760854.jpeg"]},"location":{"$ref":"#/definitions/ProfileLocation"},"properties":{"description":"An object containing key/value pairs for any custom properties assigned to this profile","type":["object","null"],"examples":[{"pseudonym":"Dr. Octopus"}]},"email":{"description":"Individual's email address","type":["string","null"],"examples":["sarah.mason@klaviyo-demo.com"]}}},"meta":{"$ref":"#/definitions/ProfileMeta"}},"required":["type","attributes"]},"ProfileEnum":{"type":"string","enum":["profile"]},"ProfileLocation":{"type":"object","properties":{"address1":{"description":"First line of street address","type":["string","null"],"examples":["89 E 42nd St"]},"address2":{"description":"Second line of street address","type":["string","null"],"examples":["1st floor"]},"city":{"description":"City name","type":["string","null"],"examples":["New York"]},"country":{"description":"Country name","type":["string","null"],"examples":["United States"]},"latitude":{"description":"Latitude coordinate. We recommend providing a precision of four decimal places.","oneOf":[{"type":"string"},{"type":"number"}],"examples":["40.7128"]},"longitude":{"description":"Longitude coordinate. We recommend providing a precision of four decimal places.","oneOf":[{"type":"string"},{"type":"number"}],"examples":["74.0060"]},"region":{"description":"Region within a country, such as state or province","type":["string","null"],"examples":["NY"]},"zip":{"description":"Zip code","type":["string","null"],"examples":["10017"]},"timezone":{"description":"Time zone name. We recommend using time zones from the IANA Time Zone Database.","type":["string","null"],"examples":["America/New_York"]},"ip":{"description":"IP Address","type":["string","null"],"examples":["127.0.0.1"]}}},"ProfileMeta":{"type":"object","properties":{"patch_properties":{"$ref":"#/definitions/ProfileMetaPatchProperties"},"patch_identifiers":{"$ref":"#/definitions/PatchIdentifiers"}}},"ProfileMetaPatchProperties":{"type":"object","properties":{"append":{"description":"Append a simple value or values to this property array","type":["object","null"],"examples":[{"skus":"92538"}]},"unappend":{"description":"Remove a simple value or values from this property array","type":["object","null"],"examples":[{"skus":"40571"}]},"unset":{"description":"Remove a key or keys (and their values) completely from properties","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"examples":["skus"]}}},"PatchIdentifiers":{"type":"object","properties":{"append":{"type":"object"},"unappend":{"type":"object"}}}}},"name":"Create or Update Push Token","id":"klaviyo.create_push_token","example":{"headers":{"revision":"2026-10-15"},"body":{"data":{"type":"push-token","attributes":{"token":"1234567890","platform":"android","vendor":"apns","profile":{"data":{"type":"profile","attributes":{}}}}}}},"maxRequests":1,"summary":false}}