Skip to content

[개발] 강아지의 Google photo 앨범 주소를 등록하는 Endpoint 생성 #23

Description

@Yoonkeee

기존 API 수정 사항

'/api/get/history-nonchecked'

Response에 url 항목 추가

[
  {
    "name": name,
    ...
    "url": (string | null)
  },
  ...
]

신규 개발 사항

API Endpoint

등록된 모든 앨범 리스트 보기

GET

'/api/get/all-albums'

Reesponse (JSON Array)

[
  {
    "name": {name},
    "url": {url}
  }
   ...
]

name에 해당하는 강아지에게 등록된 앨범 주소 보기

GET

'/api/get/album/{name}'

해당 이름의 강아지에 앨범 주소가 등록되었을 경우

Response 200 OK

{
  name: {name},
  url: {url}
}

앨범 주소가 등록되지 않았을 경우

Response 404 Not Found

앨범 주소 등록하기

POST

'/api/post/album'
Request Body

{
  "data": {
    "name": {name},
    "url": {url}
  }
}

앨범 주소 등록에 성공했을 경우

Response 200 OK

실패했을 경우

Response 400 Bad Request


Deprecated

Google photo API Docs

Google API OAuth 2.0 Docs

API

POST 
https://photoslibrary.googleapis.com/v1/albums
Content-type: application/json
Authorization: Bearer oauth2-token

Request Body

{
  "album": {
    "title": "new-album-title"
  }
}

Response Body

{
  "productUrl": "album-product-url",
  "id": "album-id",
  "title": "album-title",
  "isWriteable": "whether-you-can-write-to-this-album"
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions