POST/users/{userId}/mail/settings/forwarding

Enables email forwarding,

which forwards incoming email messages to a specified email address.

Authorization

oauth2

OAuth 2.0 authentication.
For more information, see Authentication and Authorization.

Scope

mail

HTTP Request

POSThttps://www.worksapis.com/v1.0/users/{userId}/mail/settings/forwarding

Path Parameters

ParameterTypeDescription
userId string 

Member ID (must be URL-encoded)

  • User ID
  • Login ID (email)
  • Me

required
example : me 

Header Parameters

HeadertypeDescription
Authorization string 

Bearer {token}


required 
Content-Type string 

application/json


required
example : application/json 

Request Body

PropertyTypeDescription
email string 

Email address (RFC822 format)


required
minLength : 1
format : email 
isSaveOriginalMail boolean 

Indicates whether to save the original email message.

  • true: Save the original message (default).
  • false: Move the original message to Trash.

default : true 

Request Example

example

1{2  "email": "ex001@example.com",3  "isSaveOriginalMail": false4}

Response

HTTP 201

Created

HTTP 400

Bad Request

HTTP 401

Unauthorized