본문 바로가기메인 메뉴 바로가기사이드 메뉴 바로가기

kakao developers

Related sites
  • Docs
  • Kakao Talk Channel
  • REST API

사이드 메뉴

Search

This document describes how to integrate Kakao Talk Channel APIs into your service with a REST API.

MethodURLAuthorization
GEThttps://kapi.kakao.com/v2/api/talk/channelsAccess token
Service app admin key
PermissionPrerequisiteKakao LoginUser consent
RequiredAdmin key
Activate Kakao Login
Manage consent items
Set Kakao Talk Channel
RequiredRequired:
Kakao Talk Channel addition status and details

Returns the relationship between the current user and Kakao Talk Channels connected to your app.

Providing a new API

We provide the v2 version for checking Kakao Talk Channel relationship API. You can find information of the v1 API in a separate document.

Kakao Talk Channel webhook

To get a notification when a user adds or blocks one of your Kakao Talk Channels linked to you service, use the Kakao Talk Channel webhook function.

If an error occurs because the user has not consented to the Kakao Talk Channel addition status and details consent item, use Request additional consent to request consent.

NameDescriptionRequired
AuthorizationAuthorization: Bearer ${ACCESS_TOKEN}
Access token as a type of user authentication.
O
NameTypeDescriptionRequired
channel_idsStringList of Kakao Talk Channel profile IDs that you want to check the relationship with a user.
A comma-separated string.
(Example: _Bxkd,_RQxl,_vxfxm, default: all Kakao Talk Channel profile IDs linked to the app)
X
channel_id_typeStringA type of the Kakao Talk Channel profile ID.
Fixed to channel_public_id.
X
NameDescriptionRequired
AuthorizationAuthorization: KakaoAK ${SERVICE_APP_ADMIN_KEY}
Service app admin key as a type of user authentication.
O
Content-TypeContent-Type: application/x-www-form-urlencoded;charset=utf-8
The data type of the request.
O
NameTypeDescriptionRequired
target_id_typeStringA type of the user ID.
Fixed to user_id.
O
target_idLongService user ID.O
channel_idsStringList of Kakao Talk Channel profile IDs that you want to check the relationship with a user.
A comma-separated string.
(Example: _Bxkd,_RQxl,_vxfxm, default: all Kakao Talk Channel profile IDs linked to the app)
X
channel_id_typeStringA type of the Kakao Talk Channel profile ID.
Fixed to channel_public_id.
X
NameTypeDescriptionRequired
user_idLongService user ID.O
channelsChannels[]Kakao Talk Channel information.X
NameTypeDescriptionRequired
channel_uuidStringKakao Talk Channel profile ID for search purpose.O
channel_public_idStringKakao Talk Channel profile ID.O
relationStringRelationship between a Kakao Talk Channel and a user.
ADDED: a user has added the channel.
BLOCKED: a user has blocked the channel.
NONE: a user has not either added or blocked the channel.
O
created_atDatetimeTime when a Kakao Talk Channel is added in UTC*.
Only returned if a Kakao Talk Channel is added (ADDED).
X
updated_atDatetimeTime when a Kakao Talk Channel relationship is changed in UTC*.
Only returned if a Kakao Talk Channel is added (ADDED) or blocked (BLOCKED).
X
*The time is based on Coordinated Universal Time(UTC), being 9 hours behind Korean Standard Time(KST). For the format of time, refer to RFC3339: Date and Time on the Internet.
curl -v -G GET "https://kapi.kakao.com/v2/api/talk/channels" \
-H "Authorization: Bearer ${ACCESS_TOKEN}" \
-d "channel_ids=_frxjem,_xnrxjem,_Brxjem"
curl -v -G GET "https://kapi.kakao.com/v2/api/talk/channels" \
-H "Authorization: KakaoAK ${SERVICE_APP_ADMIN_KEY}" \
-d "target_id_type=user_id" \
-d "target_id=${USER_ID}" \
-d "channel_ids=_frxjem,_xnrxjem,_Brxjem"
// HTTP/1.1 200 OK
{
"user_id": 1234567890, // ${USER_ID}
"channels": [
{
"channel_uuid": "@테스트",
"channel_public_id": "_ZeUTxl",
"relation": "ADDED", // One of ADDED, BLOCKED, NONE
"created_at": "2020-04-18T03:17:05Z", // Only returned when "relation" is "ADDED".
"updated_at": "2021-05-17T05:25:01Z"
} // Only returned when "relation" is "ADDED" or "BLOCKED".
// ...
]
}
// HTTP/1.1 400 Bad Request
{
"msg": "given account is not connected to any talk user.",
"code": -501
}
MethodURLAuthorization
GEThttps://kapi.kakao.com/v2/api/talk/channels/multiService app admin key
PermissionPrerequisiteKakao LoginUser consent
RequiredAdmin key
Activate Kakao Login
Manage consent items
Set Kakao Talk Channel
RequiredRequired:
Kakao Talk Channel addition status and details

Returns the relationships between multiple users and Kakao Talk Channels connected to your app.

Kakao Talk Channel webhook

To get a notification when a user adds or blocks one of your Kakao Talk Channels linked to you service, use the Kakao Talk Channel webhook function.

NameDescriptionRequired
AuthorizationAuthorization: KakaoAK ${SERVICE_APP_ADMIN_KEY}
Service app admin key as a type of user authentication.
O
Content-TypeContent-Type: application/x-www-form-urlencoded;charset=utf-8
The data type of the request.
O
NameTypeDescriptionRequired
target_id_typeStringA type of the user ID.
Fixed to user_id.
O
target_idsLongA comma-separated list of service user IDs (maximum: 200 users).O
channel_id_typeStringA type of the Kakao Talk Channel profile ID.
Fixed to channel_public_id.
X
channel_idsString[]List of Kakao Talk Channel profile IDs that you want to check the relationship with a user.
A comma-separated string.
(Default: A list of all Kakao Talk Channel profile IDs that connected to your service app)
X
이름타입설명필수
-TalkChannelsResult[]Relationship information for each user. Users whose relationship could not be checked are excluded.O
NameTypeDescriptionRequired
user_idLongService user ID.O
channelsChannels[]Kakao Talk Channel information.X
NameTypeDescriptionRequired
channel_public_idStringKakao Talk Channel profile ID.O
channel_uuidStringKakao Talk Channel profile ID for search purpose.O
relationStringRelationship between a Kakao Talk Channel and a user.
ADDED: a user has added the channel.
BLOCKED: a user has blocked the channel.
NONE: a user has not either added or blocked the channel.
O
created_atDatetimeTime when a Kakao Talk Channel is added in UTC*.
Only returned if a Kakao Talk Channel is added (ADDED).
X
updated_atDatetimeTime when a Kakao Talk Channel relationship is changed in UTC*.
Only returned if a Kakao Talk Channel is added (ADDED) or blocked (BLOCKED).
X
*The time is based on Coordinated Universal Time(UTC), being 9 hours behind Korean Standard Time(KST). For the format of time, refer to RFC3339: Date and Time on the Internet.
curl -v -G GET "https://kapi.kakao.com/v2/api/talk/channels/multi" \
-H "Authorization: KakaoAK ${SERVICE_APP_ADMIN_KEY}" \
-d "target_id_type=user_id" \
-d "target_ids=${USER_ID_1},${USER_ID_2},${USER_ID_3}" \
--data-urlencode 'channel_ids=_frxjem,_xnrxjem,_Brxjem'
// HTTP/1.1 200 OK
[
{
"user_id": 1234567890, // ${USER_ID_1}
"channels": [
{
"channel_public_id": "_xnrxjem",
"channel_uuid": "@플러스친구",
"relation": "ADDED",
"created_at": "2022-11-09T07:08:48Z",
"updated_at": "2023-07-20T07:21:05Z"
}
]
},
{
"user_id": 2345678901, // ${USER_ID_2}
"channels": [
{
"channel_public_id": "_xnrxjem",
"channel_uuid": "@플러스친구",
"relation": "NONE"
}
]
}
// ...
]
// HTTP/1.1 200 OK
[
{
"user_id": 1234567890, // ${USER_ID_1}
"channels": [
{
"channel_public_id": "_xnrxjem",
"channel_uuid": "@플러스친구",
"relation": "ADDED",
"created_at": "2022-11-09T07:08:48Z",
"updated_at": "2023-07-20T07:21:05Z"
}
]
}
]
MethodURLAuthorization
POSThttps://kapi.kakao.com/v1/talkchannel/create/target_user_fileREST API key
Service app admin key

Registers a new customer file.

  • Define the new file name in file_name and filtering criteria in schema
  • A defined schema cannot be edited
  • The file ID (file_id) returned after registration is used to add or remove users from the file

When you register a customer file through this API, you must follow the schema rules:

  • You must use the supported keys in Korean if the customer information is a string.
  • When assigning a new key, "앱유저아이디" and "전화번호" are not allowed. Only Number types are allowed for the value.
  • A schema can contain up to 30 items.
NameDescriptionRequired
AuthorizationAuthorization: KakaoAK ${APP_KEY}
REST API key or Service app admin key as a type of user authentication.
O
NameTypeDescriptionRequired
channel_public_idStringKakao Talk Channel profile ID.O
schemaJSONDefine the item and type of customer information to be registered in a customer file.
Pairs of key and value type.

Supported keys:
생년월일: birthday
국가: country
지역: region
성별: gender
연령: age
구매금액: purchase amount
포인트: point
가입일: signup date
최근 구매일: recent purchase date
응모일: event application date
(Only Korean is supported for keys.)

Value type: String or Number
O
file_nameStringName of a customer file.O
NameTypeDescription
file_idIntegerID of the customer file that has been created.
curl -v -X POST "https://kapi.kakao.com/v1/talkchannel/create/target_user_file" \
-H "Authorization: KakaoAK ${APP_KEY}" \
-H "Content-Type: application/json" \
-d '{
"channel_public_id": "_ZeUTxl",
"file_name": "vip고객리스트",
"schema":{
"생년월일":"string",
"성별":"string",
"연령":"number"
}
}'
// HTTP/1.1 200 OK
// Content-Type: application/json;charset=UTF-8
{
"file_id": 437
}
MethodURLAuthorization
GEThttps://kapi.kakao.com/v1/talkchannel/target_user_fileREST API key
Service app admin key

Returns customer file information registered for a Kakao Talk Channel.

NameDescriptionRequired
AuthorizationAuthorization: KakaoAK ${APP_KEY}
REST API key or Service app admin key as a type of user authentication.
O
NameTypeDescriptionRequired
channel_public_idStringKakao Talk Channel profile ID.O
NameTypeDescription
empty_slotIntegerThe number of available slots.
using_slotIntegerThe number of using slots.
resultsResults[]Information of each customer file registered for the Kakao Talk Channel.
NameTypeDescription
file_idIntegerFile ID.
file_nameStringFile name.
statusStringFile status.
One of using, deleting, failed.
update_atStringThe time when the file has been uploaded.
empty_slotIntegerNumber of available slots.
using_slotIntegerNumber of slots in use.
curl -v -G GET "https://kapi.kakao.com/v1/talkchannel/target_user_file" \
-H "Authorization: KakaoAK ${APP_KEY}" \
-d "channel_public_id=_ZeUTxl"
// HTTP/1.1 200 OK
// Content-Type: application/json;charset=UTF-8
{
"results": [
{
"file_id": 437,
"file_name": "VIPCustomerList",
"status": "USING",
"update_at": "2019-02-03 13:22:33",
"schema": "{\"birthday\":\"string\",\"gender\":\"string\",\"age\":\"number\"}"
}
// ...
],
"empty_slot": 27,
"using_slot": 3
}
MethodURLAuthorization
POSThttps://kapi.kakao.com/v1/talkchannel/update/target_usersREST API key
Service app admin key

Adds user information to the customer file.

What if some users are not added to the customer file?

Invalid user information and the following cases can prevent users from being added, so the requested and successfully added user counts may differ:

  • You can only add the users who have added your Kakao Talk Channel as a friend to the customer file.
  • If user_type is set to app, the value of id must be a service user ID that has been issued through Kakao Login. To do so, the user must be linked to your service through a Kakao Account.
  • If user_type is set to phone, the value of id must be the phone number used to sign up for Kakao Talk.
NameDescriptionRequired
AuthorizationAuthorization: KakaoAK ${APP_KEY}
REST API key or Service app admin key as a type of user authentication.
O
NameTypeDescriptionRequired
file_idIntegerFile ID.O
channel_public_idStringKakao Talk Channel profile ID.O
user_typeStringType of ID to be used to identify a user.
app or phone
app: service user ID of Kakao Account.
phone: mobile phone number registered in Kakao Talk.
O
usersUser[]A list of users to be added to a customer file, including IDs and schemas (maximum: 2,000 users).O
NameTypeDescriptionRequired
idStringUser ID.
Pass a service user ID or Kakao Talk phone number according to user_type.
O
fieldJSONValues for the predefined schema in key-value format.

Note: Only Number types are allowed for the value. String type value must be transferred to the Number type value by referring to a notice in Kakao Talk Channel Partner Center.
O
NameTypeDescription
file_idIntegerFile ID.
request_countIntegerNumber of users you requested to add to the customer file.
success_countIntegerNumber of users who have successfully added to the customer file.
curl -v -X POST "https://kapi.kakao.com/v1/talkchannel/update/target_users" \
-H "Authorization: KakaoAK ${APP_KEY}" \
-H "Content-Type: application/json" \
--data-urlencode '{
"file_id": 437,
"channel_public_id": "_ZeUTxl",
"user_type": "app",
"users": [
{
"id": "12345",
"field" : {
"생년월일": "2000-01-01",
"성별": "남자",
"age": 19
}
},
...
]
}'
// HTTP/1.1 200 OK
// Content-Type: application/json;charset=UTF-8
{
"file_id": 437,
"request_count": 10,
"success_count": 9
}
MethodURLAuthorization
POSThttps://kapi.kakao.com/v1/talkchannel/delete/target_usersREST API key
Service app admin key

Deletes a specific user from one of your customer files registered in the Kakao Talk Channel.

NameDescriptionRequired
AuthorizationAuthorization: KakaoAK ${APP_KEY}
REST API key or Service app admin key as a type of user authentication.
O
NameTypeDescriptionRequired
file_idIntegerFile ID.O
channel_public_idStringKakao Talk Channel profile ID.O
user_typeStringType of ID to be used to identify a user.
app or phone
app: service user ID of Kakao Account.
phone: mobile phone number registered in Kakao Talk.
O
user_idsJSON[]A list of users to be deleted from a customer file.O
curl -v -X POST "https://kapi.kakao.com/v1/talkchannel/delete/target_users" \
-H "Authorization: KakaoAK ${APP_KEY}" \
-H "Content-Type: application/json" \
--data-urlencode '{
"file_id" : 437,
"channel_public_id" : "_ZeUTxl",
"user_type" : "app"
"user_ids" : ["12345"]
}'
HTTP/1.1 200 OK
Content-Length: 0
Content-Type: application/json;charset=UTF-8

Was this helpful?

    Kakao Talk Channel > REST API - Kakao Developers | Docs