Main API인플루언서 API
POST /influence/onboarding
인플루언서 온보딩 완료
인플루언서 온보딩 완료
인플루언서 온보딩을 완료합니다. 프로필 이미지, 배송지, 계좌 정보, 약관 동의를 한 번에 처리합니다.
| 항목 | 값 |
|---|---|
| 메서드 | POST |
| 경로 | /influence/onboarding |
| 인증 | 필요 |
온보딩 완료 시 onboardingCompleted=true가 포함된 새로운 Access Token이 발급됩니다.
프론트엔드에서는 응답의 accessToken을 저장하여 사용하세요.
요청
POST /influence/onboarding HTTP/1.1
Host: api.glowb.com
Authorization: Bearer eyJhbGciOiJIUzI1NiIs...
Content-Type: application/json
{
"memberId": "user123",
"profileImageUrl": "https://example.com/profile.jpg",
"deliveryAddress": {
"addressName": "집",
"recipientName": "홍길동",
"recipientPhone": "01012345678",
"postalCode": "12345",
"baseAddress": "서울시 강남구 테헤란로 123",
"detailAddress": "101호",
"isDefault": true
},
"account": {
"bankCode": "KAKAO",
"accountNumber": "3333012345678",
"accountHolder": "홍길동",
"isDefault": true
},
"termsAgreed": true,
"privacyAgreed": true,
"marketingAgreed": false
}curl -X POST "https://api.glowb.com/influence/onboarding" \
-H "Authorization: Bearer {access_token}" \
-H "Content-Type: application/json" \
-d '{
"memberId": "user123",
"profileImageUrl": "https://example.com/profile.jpg",
"deliveryAddress": {
"addressName": "집",
"recipientName": "홍길동",
"recipientPhone": "01012345678",
"postalCode": "12345",
"baseAddress": "서울시 강남구 테헤란로 123",
"detailAddress": "101호",
"isDefault": true
},
"account": {
"bankCode": "KAKAO",
"accountNumber": "3333012345678",
"accountHolder": "홍길동",
"isDefault": true
},
"termsAgreed": true,
"privacyAgreed": true,
"marketingAgreed": false
}'const response = await fetch('/influence/onboarding', {
method: 'POST',
headers: {
'Authorization': `Bearer ${accessToken}`,
'Content-Type': 'application/json'
},
body: JSON.stringify({
memberId: 'user123',
profileImageUrl: 'https://example.com/profile.jpg',
deliveryAddress: {
addressName: '집',
recipientName: '홍길동',
recipientPhone: '01012345678',
postalCode: '12345',
baseAddress: '서울시 강남구 테헤란로 123',
detailAddress: '101호',
isDefault: true
},
account: {
bankCode: 'KAKAO',
accountNumber: '3333012345678',
accountHolder: '홍길동',
isDefault: true
},
termsAgreed: true,
privacyAgreed: true,
marketingAgreed: false
})
});
const data = await response.json();
// 새 토큰 저장
localStorage.setItem('accessToken', data.data.accessToken);Request Body 스키마
Prop
Type
DeliveryAddressRequestDto
Prop
Type
AccountRequestDto
Prop
Type
BankCode Enum
| 코드 | 은행명 |
|---|---|
IM_BANK | iM뱅크 |
KB | KB국민은행 |
SHINHAN | 신한은행 |
WOORI | 우리은행 |
HANA | 하나은행 |
NH | NH농협은행 |
IBK | IBK기업은행 |
SC | SC제일은행 |
CITI | 한국씨티은행 |
BUSAN | 부산은행 |
GWANGJU | 광주은행 |
JEJU | 제주은행 |
JEONBUK | 전북은행 |
KYONGNAM | 경남은행 |
KFCC | 새마을금고 |
CU | 신협 |
FSB | 저축은행 |
EPOST | 우체국 |
KBANK | 케이뱅크 |
KAKAO | 카카오뱅크 |
TOSS | 토스뱅크 |
응답
성공 응답 (200 OK)
{
"status": 200,
"code": null,
"message": "온보딩이 완료되었습니다.",
"data": {
"memberId": "user123",
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"profileImageUrl": "https://example.com/profile.jpg",
"deliveryAddress": {
"id": 1,
"addressName": "집",
"recipientName": "홍길동",
"recipientPhone": "01012345678",
"postalCode": "12345",
"baseAddress": "서울시 강남구 테헤란로 123",
"detailAddress": "101호",
"isDefault": true
},
"account": {
"id": 1,
"bankCode": "KAKAO",
"bankName": "카카오뱅크",
"accountNumber": "3333012345678",
"accountHolder": "홍길동",
"isDefault": true
},
"termsAgreed": true,
"privacyAgreed": true,
"marketingAgreed": false
}
}응답의 accessToken에는 onboardingCompleted: true 클레임이 포함되어 있습니다.
이 토큰을 저장하여 이후 API 호출에 사용하세요.
에러 응답
| 상태 코드 | 설명 |
|---|---|
400 | 필수 필드 누락 또는 유효성 검증 실패 |
401 | 인증 실패 |
404 | 회원을 찾을 수 없음 |
{
"status": 400,
"code": "VALIDATION_ERROR",
"message": "이용약관에 동의해야 합니다",
"data": null
}토큰 클레임
온보딩 완료 후 발급되는 토큰에는 다음 클레임이 포함됩니다:
{
"auth": [{"authority": "ROLE_USER"}],
"userId": "user123",
"userImage": "https://d3mp6eqt0w2808.cloudfront.net/img/ai/portfolio/profile/user123",
"username": "홍길동",
"onboardingCompleted": true,
"sub": "user123",
"iat": 1738254120,
"exp": 1739463720
}