> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aiderx.io/llms.txt
> Use this file to discover all available pages before exploring further.

# 활동 로그 기록

> 광고 최적화 및 분석을 위한 사용자 활동 로그를 기록합니다.

지원되는 활동 유형:
- `activity.item_view`: 상품 상세 페이지 조회를 기록합니다.
- `activity.item_click`: 카탈로그 항목 클릭을 기록합니다.
- `activity.add_cart`: 장바구니 추가 이벤트를 기록합니다.
- `activity.page_view`: 페이지 탐색 이벤트를 기록합니다.
- `activity.search`: 검색어 이벤트를 기록합니다.
- `activity.purchase`: 구매 완료를 기록합니다.
- `activity.wait`: 대기 이벤트를 기록합니다.
- `activity.resv`: 예약 이벤트를 기록합니다.
- `activity.bmrk`: 북마크 이벤트를 기록합니다.

요청은 다운스트림 DMP 처리를 위해 수락됩니다. 실제 처리와 영속화는 다운스트림에서 수행되며 이 문서에서 지정하지 않습니다.



## OpenAPI

````yaml /openapi/decision.api.ko-dev.json post /dmp/v0/log/activity
openapi: 3.1.0
info:
  contact:
    email: a2support@aiderx.io
    name: A2 Support
    url: https://aiderx.io
  description: |-
    ### 소개
    Decision API는 사용자 요청 또는 컨텍스트 정보를 바탕으로 광고나 콘텐츠를 실시간으로 선택하고 배포합니다.
    빠른 응답과 동적 기능을 통해 최적의 광고 또는 추천을 제공하여 사용자가 가능한 가장 높은 가치를 얻도록 합니다.

    다양한 알고리즘, 머신러닝 모델 및 규칙 기반 로직을 적용할 수 있어 시스템이 끊임없이 변하는 조건에 유연하게 적응할 수 있습니다.
  title: Decision API
  version: dev
  x-logo:
    altText: A2 Logo
    url: >-
      https://cdn.prod.website-files.com/668de9e1f25ab5675d87758d/6690cf1bdce95af5e3522c25_a2_logo_800_250.png
servers: []
security: []
tags:
  - description: 광고 요청, 캐시 설정 및 광고 제공 모듈의 기타 매개변수를 구성하기 위한 API입니다.
    name: Ad Serving
  - description: 추천 요청을 위한 API
    name: Recommendation Serving
  - description: >-
      광고 제공 서버의 캐시를 조작하기 위한 API입니다.


      ### **중요**

      Serving 서버의 광고 또는 추천 관련 캐시 데이터를 직접 조작하는 경우 Ad Manager에서 광고 또는 추천 데이터를 함께
      수정하지 않는 것을 **강력히 권장합니다.**


      대신 모든 광고 또는 추천 데이터 변경은 Ad Manager API를 통해 처리하는 것을 **권장합니다.**

      Serving 서버에서 변경한 내용은 Ad Manager에 반영되지 않으므로 **데이터 무결성**이 손상될 수 있습니다.
    name: Cache Management
  - description: 광고 서빙 서버 설정 API
    name: Configuration
  - description: 광고 또는 추천과 관련된 전환, 노출 및 클릭 로그를 수신하는 API입니다.
    name: Ad Log
paths:
  /dmp/v0/log/activity:
    post:
      tags:
        - Activity Log
      summary: 활동 로그 기록
      description: |-
        광고 최적화 및 분석을 위한 사용자 활동 로그를 기록합니다.

        지원되는 활동 유형:
        - `activity.item_view`: 상품 상세 페이지 조회를 기록합니다.
        - `activity.item_click`: 카탈로그 항목 클릭을 기록합니다.
        - `activity.add_cart`: 장바구니 추가 이벤트를 기록합니다.
        - `activity.page_view`: 페이지 탐색 이벤트를 기록합니다.
        - `activity.search`: 검색어 이벤트를 기록합니다.
        - `activity.purchase`: 구매 완료를 기록합니다.
        - `activity.wait`: 대기 이벤트를 기록합니다.
        - `activity.resv`: 예약 이벤트를 기록합니다.
        - `activity.bmrk`: 북마크 이벤트를 기록합니다.

        요청은 다운스트림 DMP 처리를 위해 수락됩니다. 실제 처리와 영속화는 다운스트림에서 수행되며 이 문서에서 지정하지 않습니다.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ActivityLog'
        required: true
      responses:
        '200':
          description: 다운스트림 처리를 위해 수락됨
      security:
        - '': []
components:
  schemas:
    ActivityLog:
      oneOf:
        - allOf:
            - $ref: '#/components/schemas/ItemViewEvent'
          properties:
            schema:
              const: activity.item_view
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/ItemClickEvent'
          properties:
            schema:
              const: activity.item_click
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/AddCartEvent'
          properties:
            schema:
              const: activity.add_cart
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/PageViewEvent'
          properties:
            schema:
              const: activity.page_view
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/SearchEvent'
          properties:
            schema:
              const: activity.search
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/PurchaseEvent'
          properties:
            schema:
              const: activity.purchase
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/WaitingEvent'
          properties:
            schema:
              const: activity.wait
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/ReservationEvent'
          properties:
            schema:
              const: activity.resv
              type: string
          required:
            - schema
          type: object
        - allOf:
            - $ref: '#/components/schemas/BookmarkEvent'
          properties:
            schema:
              const: activity.bmrk
              type: string
          required:
            - schema
          type: object
    ItemViewEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
      type: object
    ItemClickEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
      type: object
    AddCartEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
      type: object
    PageViewEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
      type: object
    SearchEvent:
      properties:
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        query:
          type: string
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - query
      type: object
    PurchaseEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        revenue:
          $ref: '#/components/schemas/Revenue'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
        - revenue
      type: object
    WaitingEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
      type: object
    ReservationEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        revenue:
          $ref: '#/components/schemas/Revenue'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
        - revenue
      type: object
    BookmarkEvent:
      properties:
        catalogs:
          items:
            $ref: '#/components/schemas/Catalog'
          type: array
        channel:
          description: '활동이 발생한 채널입니다(예: ''web'', ''mobile'', ''app'').'
          type: string
        device:
          anyOf:
            - $ref: '#/components/schemas/Device'
            - type: 'null'
          description: 선택적 AdCom v1.0 디바이스 정보입니다.
        device_id:
          description: 사용된 디바이스의 고유 식별자입니다.
          type: string
        id:
          description: 활동 이벤트의 선택적 고유 식별자입니다.
          type:
            - string
            - 'null'
        page_id:
          description: 활동이 발생한 특정 페이지의 선택적 식별자입니다.
          type:
            - string
            - 'null'
        timestamp:
          description: 활동이 발생한 시점의 Unix 타임스탬프입니다.
          format: int64
          type: integer
        user_id:
          description: 활동을 수행하는 사용자의 고유 식별자입니다.
          type: string
      required:
        - timestamp
        - channel
        - user_id
        - device_id
        - catalogs
      type: object
    Catalog:
      properties:
        id:
          description: 카탈로그 항목의 고유 식별자
          type: string
      required:
        - id
      type: object
    Device:
      properties:
        ext:
          description: 광고 시스템별 확장을 위한 예약 필드
        geo:
          anyOf:
            - $ref: '#/components/schemas/Geo'
            - type: 'null'
          description: 사용자의 현재 위치로 간주되는 기기의 위치 정보. Geo 객체로 정의됨.
        ip:
          description: 기기와 가장 가까운 IPv4 주소.
          type:
            - string
            - 'null'
        ua:
          description: >-
            브라우저의 User-Agent 문자열입니다. 브라우저의 원시 사용자 에이전트 문자열을 나타냅니다. 하위 호환성을 위해 최종
            사용자의 디바이스에서 사용할 수 있으면 대체 표현인 User-Agent Client-Hints로 `sua`를 채우더라도
            `ua`를 User-Agent 문자열로 채우는 것이 권장됩니다. 이 필드에는 추론하거나 근사한 사용자 에이전트를 사용하지
            않습니다. 클라이언트가 User-Agent Client Hints를 지원하고 `sua` 필드가 있으면 입찰자는 디바이스
            유형, 브라우저 유형 및 버전과 사용자 에이전트 정보에 의존하는 기타 목적을 감지할 때 `sua`를 사용하고 `ua`를
            무시하는 것이 권장됩니다. `ua`에는 동결되거나 축소된 사용자 에이전트 문자열이 포함될 수 있기 때문입니다.
          type:
            - string
            - 'null'
      type: object
    Revenue:
      properties:
        currency:
          description: The currency code for the transaction (e.g., 'USD', 'KRW')
          type: string
        revenue:
          description: The monetary amount of the transaction
          format: double
          type: number
      required:
        - revenue
        - currency
      type: object
    Geo:
      properties:
        accuracy:
          format: int32
          type:
            - integer
            - 'null'
        city:
          type:
            - string
            - 'null'
        country:
          type:
            - string
            - 'null'
        ext: true
        ipservice:
          anyOf:
            - $ref: '#/components/schemas/IpLocationService'
            - type: 'null'
        lastfix:
          format: uint32
          minimum: 0
          type:
            - integer
            - 'null'
        lat:
          format: float
          type:
            - number
            - 'null'
        lon:
          format: float
          type:
            - number
            - 'null'
        metro:
          type:
            - string
            - 'null'
        region:
          type:
            - string
            - 'null'
        regionfips104:
          type:
            - string
            - 'null'
        type:
          anyOf:
            - $ref: '#/components/schemas/LocationType'
            - type: 'null'
        utcoffset:
          format: int32
          type:
            - integer
            - 'null'
        zip:
          type:
            - string
            - 'null'
      type: object
    IpLocationService:
      enum:
        - 1
        - 2
        - 3
        - 4
      type: integer
    LocationType:
      enum:
        - 1
        - 2
        - 3
      type: integer

````