Skip to main content

Sets Email Address for Loyalty ID

PUT 

/client/users/:correlation_id/profile/email

  • This call captures an email address and associates it with a ghost card.

  • The status parameter in the request indicates the user’s email prompt preference.

  • Valid status in the request includes: deferred, accepted, and declined.

  • If the userStatus in Start Session request is "CLOSED" then the email address cannot be updated.

Request

Body

AttributeDefinitionFormatNotes
emailAddressThe email address to be associated with a ghost card.String
statusThe email user's prompt preference.Enum: "deferred", "accepted", or "declined""deferred" means "ask me another time"

Response

AttributeDefinitionFormatNotes
messageShows that an email address has been setString"Email option updated."

Error Responses

statusCodeerrorMessageerrorCodeDefinition
400 Bad RequestThe document path provided in the update expression is invalid for updateINVALID_REQUESTCannot complete update with document path provided
400 Bad RequestEmail address is requiredINVALID_REQUESTWhen body’s status is ‘accepted’ and no email is provided
400 Bad RequestEmail address not expected when status is declinedINVALID_REQUESTWhen body’s status is ‘declined’ and an email is provided
400 Bad RequestEmail address not expected when status is deferredINVALID_REQUESTWhen body’s status is ‘deferred’ and an email is provided
400 Bad RequestEmail capture option {status} is not supported!INVALID_REQUESTWhen body’s status is different from the following options: ‘accepted’, ‘deferred’, ‘declined’

Request

Responses

200 - Email Address Set

Response Headers
    Date
    Example: Thu, 21 May 2020 03:22:47 GMT
    Content-Length
    Example: 35
    Connection
    Example: keep-alive
    x-amzn-RequestId
    Example: 92a892ab-6caa-45a7-8774-65fbfb39d516
    Referrer-Policy
    Example: no-referrer
    X-XSS-Protection
    Example: 1;mode=block
    Access-Control-Allow-Origin
    Example: *
    Expect-CT
    Example: max-age=86400
    Strict-Transport-Security
    Example: max-age=31536000
    Feature-Policy
    Example: vibrate 'none'; geolocation 'none'
    X-Frame-Options
    Example: sameorigin
    Content-Security-Policy
    Example: connect-src 'none';object-src https://*.cloudfront.net;script-src https://*.cloudfront.net
    x-amz-apigw-id
    Example: M3MRHH0XIAMFpnA=
    cache-control
    Example: no-cache, no-store, must-revalidate
    X-Content-Type-Options
    Example: nosniff
    X-Amzn-Trace-Id
    Example: Root=1-5ec5f407-5c4e032b32974553017ad727;Sampled=0