728x90
반응형
내가 가지고 있는 토픽을 조회하려고 한다.
# 조회하는 방법
1) sns를 import 한다
github.com/aws/aws-sdk-go/service/sns
2) sess에는 AWS 정보들이 있는 변수
svc := sns.New(sess)
3) 토픽 리스트를 조회할 수 있다.
topics, err := svc.ListTopics(nil)
# 코드 참조
https://docs.aws.amazon.com/ko_kr/sdk-for-go/v1/developer-guide/making-requests.html
Using the AWS SDK for Go with AWS Services - AWS SDK for Go (version 1)
Using the AWS SDK for Go with AWS Services To make calls to an AWS service, you must first construct a service client instance with a session. A service client provides low-level access to every API action for that service. For example, you create an Amazo
docs.aws.amazon.com
# 참조
https://github.com/YooGenie/send-message-service/issues/3
SNS 토픽을 조회한다 · Issue #3 · YooGenie/send-message-service
github.com
+ 하면서 느낀 점은 참조할 수 있는 코드 자세히 써있어서 접근하기가 좋았다.
728x90
반응형
'사이드 프로젝트 > Amazon SQS' 카테고리의 다른 글
[Amazon SQS] SNS를 통해 FIFO방식으로 SQS에 메시지 보내기 (0) | 2022.11.15 |
---|---|
[Amazon SNS] SNS 토픽을 구독한 메일로 메시지를 보낸다 (0) | 2022.11.02 |
[Amazon SNS] AWS에서 topic를 생성한다 - 이메일용 (0) | 2022.10.19 |
[Amazon SNS] aws를 연결하기 (0) | 2022.09.28 |
[비동기프로그래밍] CLI통해 aws 접근하기 (0) | 2022.09.14 |