{"id":18035738,"url":"https://github.com/ryanlintott/wordpressreader","last_synced_at":"2025-03-27T08:30:34.589Z","repository":{"id":63920440,"uuid":"368637863","full_name":"ryanlintott/WordpressReader","owner":"ryanlintott","description":"A simple asynchronous way to download and decode public Wordpress content.","archived":false,"fork":false,"pushed_at":"2025-03-04T11:48:23.000Z","size":1662,"stargazers_count":10,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-23T10:35:30.256Z","etag":null,"topics":["rest-api","swift","wordpress"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ryanlintott.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-05-18T18:58:51.000Z","updated_at":"2025-03-04T14:21:52.000Z","dependencies_parsed_at":"2024-01-15T03:59:51.075Z","dependency_job_id":"a5829006-8395-44ee-836e-a58c542f858c","html_url":"https://github.com/ryanlintott/WordpressReader","commit_stats":{"total_commits":25,"total_committers":2,"mean_commits":12.5,"dds":0.12,"last_synced_commit":"3ff57201bc4070536a6af1aa3bb116cbb6c552da"},"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanlintott%2FWordpressReader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanlintott%2FWordpressReader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanlintott%2FWordpressReader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanlintott%2FWordpressReader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ryanlintott","download_url":"https://codeload.github.com/ryanlintott/WordpressReader/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245809564,"owners_count":20676008,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["rest-api","swift","wordpress"],"created_at":"2024-10-30T12:09:23.746Z","updated_at":"2025-03-27T08:30:34.147Z","avatar_url":"https://github.com/ryanlintott.png","language":"Swift","readme":"\u003cimg width=\"456\" alt=\"WordpressReader Logo\" src=\"https://user-images.githubusercontent.com/2143656/169389736-b28c8b3d-ec43-4714-a815-69d2e1672910.png\"\u003e\n\n[![Swift Compatibility](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fryanlintott%2FWordpressReader%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/ryanlintott/WordpressReader)\n[![Platform Compatibility](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fryanlintott%2FWordpressReader%2Fbadge%3Ftype%3Dplatforms)](https://swiftpackageindex.com/ryanlintott/WordpressReader)\n![License - MIT](https://img.shields.io/github/license/ryanlintott/WordpressReader)\n![Version](https://img.shields.io/github/v/tag/ryanlintott/WordpressReader?label=version)\n![GitHub last commit](https://img.shields.io/github/last-commit/ryanlintott/WordpressReader)\n[![Mastodon](https://img.shields.io/badge/mastodon-@ryanlintott-5c4ee4.svg?style=flat)](http://mastodon.social/@ryanlintott)\n[![Twitter](https://img.shields.io/badge/twitter-@ryanlintott-blue.svg?style=flat)](http://twitter.com/ryanlintott)\n\n# Overview\nA simple asynchronous way to download and decode public Wordpress content.\n\n# Demo App\nThe `Example` folder has an app that demonstrates the features of this package.\n\n# Installation and Usage\nThis package is compatible with iOS 14+, macOS 11+, watchOS 7+, tvOS 14+, and visionOS.\n\n1. In Xcode go to `File -\u003e Add Packages`\n2. Paste in the repo's url: `https://github.com/ryanlintott/WordpressReader` and select by version.\n3. Import the package using `import WordpressReader`\n\n# Is this Production-Ready?\nReally it's up to you. I currently use this package in my own [Old English Wordhord app](https://oldenglishwordhord.com/app).\n\nAdditionally, if you find a bug or want a new feature add an issue and I will get back to you about it.\n\n# Support\nWordpressReader is open source and free but if you like using it, please consider supporting my work.\n\n[![ko-fi](https://ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/X7X04PU6T)\n\n- - -\n# Features\n\nCreate an instance of WordpressSite for any Wordpress.com website:\n\n```swift\nlet site = WordpressSite(domain: \"oldenglishwordhord.com\", name: \"Old English Wordhord\")\n```\n\nFetch posts, pages, categories, or tags asynchronously:\n\n```swift\nlet posts: [WordpressPost] = try await site.fetch(.posts())\nlet pages: [WordpressPage] = try await site.fetch(.pages())\nlet categories: [WordpressCategory] = try await site.fetch(.categories())\nlet tags: [WordpressTag] = try await site.fetch(.tags())\n```\n\nAdd a set of WordpressQueryItem to narrow down your request:\n\n```swift\nlet request = WordpressRequest.posts([.postedAfter(aWeekAgo), .order(.asc), perPage(10)])\nlet posts = try await site.fetch(request)\n```\n\nWordpress queries may result in several pages of items. You can customize your WordpressRequest to get the first page out quickly:\n```swift\nvar recentPosts = WordpressRequest.posts()\nrecentPosts.maxPages = 1\n\nvar remainingPosts = WordpressRequest.posts()\nremainingPosts.startPage = 2\n\nself.posts = try await site.fetch(recentPosts)\nself.posts += try await site.fetch(remainingPosts)\n```\n\nThe default .fetch() will get pages in parallel but only return when they're all done. If you want each batch in order as soon as they're ready, use an async stream:\n\n```swift\nfor try await batch in try await site.stream(request) {\n  self.posts += posts\n}\n```\n","funding_links":["https://ko-fi.com/X7X04PU6T"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanlintott%2Fwordpressreader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fryanlintott%2Fwordpressreader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanlintott%2Fwordpressreader/lists"}