Enumeration
Endpoint
public enum Endpoint
A module-like enum
defining all possible Endpoint
s.
Relationships
Nested Types
Endpoint.Group
A module-like
enum
to hide away endpoint wrappers definitions.
Nested Type Aliases
Properties
Methods
location(_:)
A wrapper for location endpoints.
Parameters
Name | Type | Description |
---|---|---|
identifier | String |
A valid |
Returns
A valid Location
.
location(_:)
A summary for the location media.
Parameters
Name | Type | Description |
---|---|---|
identifier | String |
A valid |
Returns
A valid Endpoint.Single
.
locations(around:matching:)
static func locations(around coordinates: Swiftagram.Location.Coordinates,
matching query: String? = nil) -> Endpoint.Single<Swiftagram.Location.Collection, Error>
A list of locations around the given coordiantes, matching an optional query.
Parameters
Name | Type | Description |
---|---|---|
coordinates | Swiftagram.Location.Coordinates |
Some valid |
query | String? |
An optional |
Returns
A valid Endpoint.Single
.
media(_:)
A wrapper for media endpoints.
Parameters
Name | Type | Description |
---|---|---|
identifier | String |
A valid |
Returns
A valid Endpoint.Media
.
media(_:)
A wrapper for media endpoints.
Parameters
Name | Type | Description |
---|---|---|
media | Swiftagram.Media |
A valid |
Returns
A valid Endpoint.Media
.
media(_:)
A summary for the current media.
Parameters
Name | Type | Description |
---|---|---|
identifier | String |
A valid |
Returns
A valid Endpoint.Single
.
media(at:)
A wrapper for media endpoints.
Parameters
Name | Type | Description |
---|---|---|
url | URL |
A valid |
Throws
Some Media.Error
.
Returns
A valid Media
.
media(at:)
A summary for the media at the given url.
Parameters
Name | Type | Description |
---|---|---|
url | URL |
A valid |
Returns
A valid Endpoint.Single
.
stories(_:)
static func stories<C: Collection>(_ identifiers: C) -> Endpoint.Single<TrayItem.Dictionary, Error> where C.Element == String
An endpoint for loading specific endpoints.
Parameters
Name | Type | Description |
---|---|---|
identifiers | C |
A collection of |
Returns
A valid Endpoint.Single
.
tag(_:)
static func tag(_ name: String) -> Group.Tag
A wrapper for tag-specific endpoints.
Parameters
Name | Type | Description |
---|---|---|
name | String |
A valid |
Returns
A valid Tag
.
tag(_:)
A summary for the current tag.
Parameters
Name | Type | Description |
---|---|---|
name | String |
A valid |
Returns
A valid Endpoint.Single
.
users(_:)
static func users<C: Collection>(_ identifiers: C) -> Group.ManyUsers where C.Element == String
A wrapper for users specific endpoints.
Parameters
Name | Type | Description |
---|---|---|
identifiers | C |
A collection of |
Returns
A valid Endpoint.ManyUsers
.
users(_:)
static func users<C: Collection>(_ users: C) -> Group.ManyUsers where C.Element == Swiftagram.User
A wrapper for users specific endpoints.
Parameters
Name | Type | Description |
---|---|---|
users | C |
A collection of |
Returns
A valid Endpoint.ManyUsers
.
user(_:)
static func user(_ identifier: String) -> Group.User
A wrapper for user endpoints.
Parameters
Name | Type | Description |
---|---|---|
identifier | String |
A valid |
Returns
A valid EndpointUser
.
user(_:)
A wrapper for user endpoints.
Parameters
Name | Type | Description |
---|---|---|
user | Swiftagram.User |
A valid |
Returns
A valid Endpoint.User
.
user(_:)
A summary for a given user.
Parameters
Name | Type | Description |
---|---|---|
identifier | String |
A valid |
Returns
A valid Endpoint.Single
.
user(matching:)
A summary for a user which username exactly matches the one provided.
Parameters
Name | Type | Description |
---|---|---|
username | String |
A valid |
Returns
A valid Endpoint.Single
.
users(matching:)
static func users(matching query: String) -> Endpoint.Paginated < Swiftagram.User.Collection,
RankedOffset<String?, String?>,
Error>
All user matching query
.
Parameters
Name | Type | Description |
---|---|---|
query | String |
A |
Returns
A valid Endpoint.Pagianted
.