인스타그램 API 연동

하하하·2024년 12월 2일
2

인스타그램 계정정보 가져오기

페이지 접속
1) 인스타 공식문서 접속
https://developers.facebook.com/docs/instagram-platform/instagram-api-with-instagram-login

※ Instagram 기본 디스플레이 API는 2024년 12월 24일날 지원종료된다.
https://developers.facebook.com/docs/instagram-basic-display-api/changelog

2) Instagram professionals 계정 전환하기
광고 원리 알아보기 이건 돈내야되는데 안해도 비즈니스계정으로 된다.
비즈니스 계정 전환하는 방법
https://help.instagram.com/502981923235522

3) 페이스북 디벨로퍼 접속 => 내 앱 누르기
https://developers.facebook.com/?locale=ko_KR&nav_ref=biz_unified_f3_login_page_to_dfc



아까 등록한 프로페셔널 계정 등록

계정 생성하고 엑세스 토큰 생성하고 요청보내기

https://graph.instagram.com/v21.0/me?fields=user_id,username,media_count,account_type&access_token=생성한 액세스 토큰

상세 필드 정보
https://developers.facebook.com/docs/instagram-platform/instagram-api-with-instagram-login/get-started

인스타그램 API는 페이스북 graph-api 기반으로 작성되어있기 때문에 두 개를 동시에 봐야된다.

1) 요청 보내기
https://graph.instagram.com/v21.0/계정PK/media?access_token=토큰값 D&fields=id,caption,media_type,media_url,permalink,thumbnail_url,timestamp&limit=10&=

미디어 상세 필드 정보
https://developers.facebook.com/docs/instagram-basic-display-api/reference/media

limit = 페이징 사이즈

2) graph-api 페이징
https://developers.facebook.com/docs/graph-api/results

profile
하하하

0개의 댓글