Skip to content
Discussion options

You must be logged in to vote

Hey @karorox,

I've moved this to the Discussions tab as this is not an issue, please make sure you're starting support requests from there next time 😊

You can fetch tag-specific posts like so:

// Assuming you already have the `Secret`.
let secret: Secret = /* some `Secret` */
// Assuming this is the name of the tag.
let tag: String = "travel"
// Assuming this is retained.
var bin: Set<AnyCancellable> = []

Endpoint.tag(tag)
   .posts
   .recent   // or use `.top` for top posts.
   .unlock(with: secret)
   .session(.instagram)   // or pass your custom `URLSession`.
   .pages(1)   // to only fetch the first page.   
   .sink(receiveCompletion: { _ in }, receiveValue: { print($0) })
   .store(

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by sbertix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #202 on May 13, 2021 18:13.