IMINE Inbound API

IMINE Inbound API

imineskin.com 문의하기 폼으로 접수되는 인바운드 요청을 수신·처리하는 API입니다. An API that receives and processes inbound submissions from the imineskin.com contact form.

기본 URLBase URL

https://api.imine.afkstudio.co

인증Authentication

모든 요청은 HMAC-SHA256 서명이 필요합니다. 공유 비밀키(secret)는 별도의 보안 링크로 전달되며, 외부에 노출되지 않도록 주의해 주세요. 각 요청에 아래 두 헤더를 포함해 주세요. Every request must be signed with HMAC-SHA256. The shared secret is delivered separately via a secure link — keep it confidential. Include these two headers on every request:

헤더Header 설명Description
X-IMINE-Timestamp 요청 시각 (Unix epoch ).Request time (Unix epoch seconds).
X-IMINE-Signature 아래 방식으로 계산한 서명 (소문자 hex).The signature computed below (lowercase hex).

서명 방법: {timestamp}.{원본 요청 본문} 문자열을 비밀키로 HMAC-SHA256 해싱 후 hex로 인코딩합니다 — 본문은 재직렬화하지 말고 전송하는 바이트 그대로 사용해 주세요. 타임스탬프는 위 X-IMINE-Timestamp 값과 동일합니다. How to sign: HMAC-SHA256 the string {timestamp}.{raw request body} with the secret, hex-encoded — sign the exact body bytes you send (do not re-serialize). The timestamp is the same value as X-IMINE-Timestamp.

401 Unauthorized — 서명이 없거나 올바르지 않으면 반환됩니다. 타임스탬프가 서버 시각과 ±5분을 초과하면 거부됩니다(재전송 방지). 401 Unauthorized is returned when the signature is missing or invalid. Requests are also rejected if the timestamp is more than ±5 minutes from server time (replay protection).

인바운드 전송Send inbound

POST /inbound

인바운드 요청 1건을 application/json 본문으로 전송합니다. 아래 스키마를 따르며, 모든 필드는 선택 사항입니다 — 누락되거나 추가된 필드가 있어도 그대로 저장되며 요청이 거부되지 않습니다. 첨부파일은 다운로드 URL로 전달합니다. Submit a single inbound submission as an application/json body following the schema below. All fields are optional — missing or extra fields are stored as-is and never cause a rejection. Attachments are passed as download URLs.

요청 본문Request body

필드Field 타입Type 필수 여부Required?
id number 선택optional
uuid string 선택optional
createdAt string 선택optional
country string 선택optional
category string 선택optional
name string 선택optional
company string 선택optional
email string 선택optional
phone string 선택optional
title string 선택optional
contentHtml string 선택optional
contentText string 선택optional
attachments object[] 선택optional

응답Responses

성공 시 200과 함께 아래 본문이 반환됩니다. 정상 접수된 모든 요청은 동일한 응답을 받으므로, 2xx 응답은 모두 성공으로 간주하고 재시도하지 마세요. On success you receive 200 with the body below. Every accepted submission gets the same response, so treat any 2xx as success and do not retry.

{
  "status": "received"
}
200정상 접수되었습니다.Received successfully.
400잘못된 요청 본문.Malformed request body.
401서명 누락 또는 검증 실패.Missing or invalid signature.
500처리 실패. 재시도 가능합니다.Could not process it; safe to retry.

예시Example

서명을 포함한 전체 요청 예시입니다. SECRET을 전달받은 비밀키로 교체하세요. A complete signed request example. Replace SECRET with the shared secret you were given.

SECRET='<shared secret>'
TS=$(date +%s)
BODY='{"id":12345,"uuid":"a1b2c3d4-0000-1111-2222-333344445555","createdAt":"2026-06-27T08:30:00.000Z","country":"1016001","category":"3","name":"홍길동","company":"테스트","email":"hong@example.com","phone":"010-1234-5678","title":"세라마이드 크림 개발 문의","contentHtml":"<p>안녕하세요, 문의드립니다.</p>","contentText":"안녕하세요, 문의드립니다.","attachments":[{"name":"brief.pdf","size":20480,"downloadUrl":"https://www.imineskin.com/files/brief.pdf"}]}'

# sign: hex( HMAC-SHA256(secret, "{timestamp}.{body}") )
SIG=$(printf '%s.%s' "$TS" "$BODY" | openssl dgst -sha256 -hmac "$SECRET" | sed 's/^.* //')

curl -X POST 'https://api.imine.afkstudio.co/inbound' \
  -H "X-IMINE-Timestamp: $TS" \
  -H "X-IMINE-Signature: $SIG" \
  -H 'Content-Type: application/json' \
  --data-binary "$BODY"