Skip to content

Publish tags and categories APIs #804

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions native/swift/Sources/wordpress-api/Exports.swift
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,34 @@ public typealias MediaRequestListWithEditContextResponse = WordPressAPIInternal.
public typealias MediaRequestListWithViewContextResponse = WordPressAPIInternal.MediaRequestListWithViewContextResponse
public typealias MediaRequestListWithEmbedContextResponse = WordPressAPIInternal.MediaRequestListWithEmbedContextResponse

// MARK: - Tags
public typealias TagId = WordPressAPIInternal.TagId
public typealias SparseTag = WordPressAPIInternal.SparseTag
public typealias TagWithEditContext = WordPressAPIInternal.TagWithEditContext
public typealias TagWithViewContext = WordPressAPIInternal.TagWithViewContext
public typealias TagWithEmbedContext = WordPressAPIInternal.TagWithEmbedContext
public typealias TagCreateParams = WordPressAPIInternal.TagCreateParams
public typealias TagUpdateParams = WordPressAPIInternal.TagUpdateParams
public typealias TagListParams = WordPressAPIInternal.TagListParams
public typealias TagsRequestExecutor = WordPressAPIInternal.TagsRequestExecutor
public typealias TagsRequestListWithEditContextResponse = WordPressAPIInternal.TagsRequestListWithEditContextResponse
public typealias TagsRequestListWithViewContextResponse = WordPressAPIInternal.TagsRequestListWithViewContextResponse
public typealias TagsRequestListWithEmbedContextResponse = WordPressAPIInternal.TagsRequestListWithEmbedContextResponse

// MARK: - Categories
public typealias CategoryId = WordPressAPIInternal.CategoryId
public typealias SparseCategory = WordPressAPIInternal.SparseCategory
public typealias CategoryWithEditContext = WordPressAPIInternal.CategoryWithEditContext
public typealias CategoryWithViewContext = WordPressAPIInternal.CategoryWithViewContext
public typealias CategoryWithEmbedContext = WordPressAPIInternal.CategoryWithEmbedContext
public typealias CategoryCreateParams = WordPressAPIInternal.CategoryCreateParams
public typealias CategoryUpdateParams = WordPressAPIInternal.CategoryUpdateParams
public typealias CategoryListParams = WordPressAPIInternal.CategoryListParams
public typealias CategoriesRequestExecutor = WordPressAPIInternal.CategoriesRequestExecutor
public typealias CategoriesRequestListWithEditContextResponse = WordPressAPIInternal.CategoriesRequestListWithEditContextResponse
public typealias CategoriesRequestListWithViewContextResponse = WordPressAPIInternal.CategoriesRequestListWithViewContextResponse
public typealias CategoriesRequestListWithEmbedContextResponse = WordPressAPIInternal.CategoriesRequestListWithEmbedContextResponse

// MARK: – Site Settings
public typealias SparseSiteSettings = WordPressAPIInternal.SparseSiteSettings
public typealias SiteSettingsWithEditContext = WordPressAPIInternal.SiteSettingsWithEditContext
Expand Down
12 changes: 12 additions & 0 deletions native/swift/Sources/wordpress-api/WordPressAPI.swift
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,18 @@ public actor WordPressAPI {
self.requestBuilder.siteSettings()
}

public var taxonomies: TaxonomiesRequestExecutor {
self.requestBuilder.taxonomies()
}

public var tags: TagsRequestExecutor {
self.requestBuilder.tags()
}

public var categories: CategoriesRequestExecutor {
self.requestBuilder.categories()
}

#if PROGRESS_REPORTING_ENABLED
public func uploadMedia(
params: MediaCreateParams,
Expand Down