createAddressBook
    • PDF

    createAddressBook

    • PDF

    Article Summary

    Creates an address book by getting recipient addresses or groups in bulk.
    The address book status right before creating an address book is returned as a response, and the creation task is processed asynchronously.
    The address book is changed through update or insert. (Add new addresses to the existing recipient group, or create a new recipient group)

    POST https://{endpoint}/address-book
    

    Request parameters

    Parameter nameRequired statusTypeRestrictionsDescription
    groupsYesList<AddressBookRequest>List of recipient groups including email addresses.

    Response

    HTTP status codeDescription
    201Request to create an address book was successful.
    400Authentication failed, invalid request.
    500Server errors

    Example

    Request example

    POST https://mail.apigw.ntruss.com/api/v1/address-book
    
    {
      "groups":[
        {
          "groupName":"Teens",
          "emailAddresses":[
            "xxx@naver.com",
            ...
          ]
        },
        {
          "groupName":"Male",
          "emailAddresses":[
            "xxx@daum.net",
            ...
          ]
        }
      ]
    }
    

    Response example

    {
      "totalAddressCount": 4300,
      "groups": [
        {
          "sid": 155,
          "groupName": "Teens",
          "addressCount": 3900
        },
        {
          "sid": 159,
          "groupName": "Male",
          "addressCount": 1000
        }
      ]
    }
    

    Property

    CategoryRequired statusTypeRestrictionsDescription
    totalAddressCountYesIntegerTotal number of email addresses
    groupsNoList<AddressBookResponse>List of recipient groups

    Error codes

    HTTP Status CodeReturn codeResponse message
    40077101Error in login information
    40077102BAD_REQUEST
    40077103Resource not found
    40377201No permission
    40377202No request to subscribe the email product
    40577001METHOD_NOT_ALLOWED
    41577002UNSUPPORTED_MEDIA_TYPE
    50077301Default project not found
    50077302Error in working with external system API
    50077303Other INTERNAL_SERVER_ERROR

    Was this article helpful?

    What's Next
    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.