{"action":"created","comment":{"url":"https://api.github.com/repos/xmartlabs/blog/pulls/comments/194811842","pull_request_review_id":128010608,"id":194811842,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5NDgxMTg0Mg==","diff_hunk":"@@ -0,0 +1,242 @@\n+---\n+layout: post\n+title: Android paging for Mortals part one\n+date: 2018-04-02 09:00:00\n+author: Matías Irland\n+categories: Android, Android Jetpack,Android Paging Library,Live Data, Android Architecture Components,RxJava,Retrofit\n+author_id: mirland\n+\n+---\n+\n+There're tons of articles talking about the amazing Android Architecture Components, talking about how we can combine them in an MVVM architecture and make them work as a charm.\n+From my point of view, that's true, the **Android Architecture Components are awesome!**\n+\n+There're another ton of articles talking about the new [Android Paging Library](https://developer.android.com/topic/libraries/architecture/paging/) and how we can combine it with [Room](https://developer.android.com/topic/libraries/architecture/room) and [LiveData](https://developer.android.com/topic/libraries/architecture/livedata) to make the paging as easier as possible.\n+I suppose that you have read some of them.\n+\n+So I don't want to write about the new Android Components or how we should use them.\n+Today I want to tell you, how we can **integrate a numerated paged service**, in the best way that I know, **using** the new **[XLPaging](https://github.com/xmartlabs/xlpaging) library.**\n+A numerated paged service is a service which returns a list of entities structured in pages with sequential page numbers.  \n+\n+In order to read this post, you should already know the repository architectural pattern and the basic things of these libraries:\n+1. [Retrofit](http://square.github.io/retrofit/)\n+1. [Rxjava](https://github.com/ReactiveX/RxJava)\n+1. [Android Architecture Components](https://developer.android.com/topic/libraries/architecture/)\n+\t1. [LiveData](https://developer.android.com/topic/libraries/architecture/livedata)\n+\t1. [Room Persistence Library](https://developer.android.com/topic/libraries/architecture/room)\n+\t1. [Android Paging Library](https://developer.android.com/topic/libraries/architecture/paging/)\n+\n+\n+# Listing Component\n+First of all I want to tell you a cool Google idea, that they are using in some of their [example projects](https://github.com/googlesamples/android-architecture) to handle all services which contains a list.\n+\n+They think that you can handle all list streams with a `Listing` component which contains basically five elements:\n+\n+```kotlin\n+data class Listing<T>(\n+    val pagedList: LiveData<PagedList<T>>,\n+    val networkState: LiveData<NetworkState>,\n+    val refresh: () -> Unit,\n+    val refreshState: LiveData<NetworkState>,\n+    val retry: () -> Unit\n+)\n+```\n+\n+1. A changing data stream of the type `T` represented as [`LiveData`](https://developer.android.com/topic/libraries/architecture/livedata) of a [`PagedList`](https://developer.android.com/reference/android/arch/paging/PagedList).\n+1. A stream which contains the networking state changes.\n+1. A refresh function, to refresh all data.\n+1. A stream which contains the status of the refresh request.\n+1. A retry function, in order to be able to execute it if something failed.\n+\n+The networking state could be represented as:\n+```kotlin\n+enum class Status {\n+  RUNNING,\n+  SUCCESS,\n+  FAILED\n+}\n+\n+data class NetworkState private constructor(\n+    val status: Status,\n+    val throwable: Throwable? = null) {\n+\n+  companion object {\n+    val LOADED = NetworkState(Status.SUCCESS)\n+    val LOADING = NetworkState(Status.RUNNING)\n+    fun error(throwable: Throwable?) = NetworkState(Status.FAILED, throwable)\n+  }\n+}\n+```\n+\n+## The problem\n+Suppose that you are following the repository pattern and you want to expose a paginated list of entities from a service source.\n+In that case, your repository should implement a method which returns a `Listing` of that entities.\n+\n+I'll give you an example, suppose that you have an app which lists the github users whose usernames contain a specific word.\n+\n+So, if you use Retrofit and RxJava you can define the service call as:\n+\n+```kotlin\n+data class GhListResponse<T>(val total_count: Long, private val items: List<T>)\n+\n+data class User(var id: Long, @SerializedName(\"login\") var name: String?, var avatarUrl: String?)\n+\n+@GET(\"/search/users\")\n+fun searchUsers(@Query(\"q\") name: String,\n+                @Query(\"page\") page: Int,\n+                @Query(\"per_page\") pageSize: Int\n+): Single<GhListResponse<User>>\n+```\n+\n+This service is pretty similar to the majority of the paged services that I've seen, so the big question here is how we could integrate this service in a repository using the new Paging Component.\n+Furthermore, the question could be how we could convert the `Single<GhListResponse<User>>` response in a `Listing<User>` structure.\n+\n+The first question that we should do to solve this problem is: do we want to have a database source to cache the data?\n+That's a complicated question, the answer could be that if we want to search entities by a key, maybe a database cache couldn't be the best option.\n+The response could change a lot in a short period of time and maybe the user doesn't use to do the same search multiple times.\n+However, saving data in a database source sometimes could have some advantages.\n+For example, you can provide offline support, make less usage of the server, \"hide\" network problems, do a better manage of the data and be able to share entities easier.\n+\n+Personally, I prefer using the second one, but I know that depending your problem or your use case both options could be valid.\n+In this post we will see that both strategies could be implemented using **[Xlpaging](https://github.com/xmartlabs/xlpaging)**. \n+\n+# XLPaging\n+[XLPaging](https://github.com/xmartlabs/xlpaging) is an **Android Kotlin library** which provides two main features for people who work with paginated services, where the paginated strategy of that services are based on an incremental page number.\n+Those features are:\n+- Provide a `Listing` structure based on a Retrofit & RxJava service.\n+- Provide a `Listing` structure with cache support using Retrofit and RxJava for the service layer and a [`DataSource`](https://developer.android.com/reference/android/arch/paging/DataSource) for caching the data. In the examples we will use [Room](https://developer.android.com/topic/libraries/architecture/room) to provide the `DataSource` but you could use any other `DataSource`.\n+\n+In this post we'll see how we can integrate the first functionality.\n+The second one will be explained in the next post.\n+\n+## XLPaging Network support\n+The library defines two structures to handle the network requests.\n+The `PageFetcher` is used to fetch each page from the service, whereas the `PagingHandler` will be used to handle the paging state.\n+\n+```kotlin\n+interface PageFetcher<T> {\n+  @CheckResult\n+  fun fetchPage(page: Int, pageSize: Int): Single<out T>\n+}\n+\n+interface PagingHandler<T> : PageFetcher<T> {\n+  @CheckResult\n+  fun canFetch(page: Int, pageSize: Int): Boolean\n+}\n+```\n+So the paging state will be managed by the library using mainly two methods:\n+- The first one, is a method to fetch an specific page, by a page number and a page size.\n+This method should return a `Single<out T>`, where `T` could be anything.\n+- The second one, is a method to check if a page can be fetched.\n+For example, if you know that the server has only 3 pages of 10 items each one, if the library invokes `canFetch(page = 5, pageSize = 10)` you should return `false`.\n+You have to implement this function using the service specifications.\n+Sometime the service returns the amount of pages or the amount of entities in the response headers or in the response body, so you have to use that information to implement this function.\n+However, if you know exactly the amount of pages or the amount of entities, the library provides a way to make this work easier.\n+I will show that later.\n+\n+\n+In order to use the **XLPaging Network support**, we have to implement just a `PagingHandler<ListResponse<T>>`, where the `ListResponse<T>` is how the library expects the service response.  \n+\n+```kotlin\n+interface ListResponse<T> {\n+  fun getElements(): List<T>\n+}\n+``` \n+\n+So, if we use the same Github example, our paging handler would be:\n+```kotlin\n+data class GhListResponse<T>(val total_count: Long, private val items: List<T>) : ListResponse<T> {\n+  override fun getElements() = items\n+}\n+\n+val pagingHandler = (object : PagingHandler<ListResponse<User>> {\n+      override fun canFetch(page: Int, pageSize: Int): Boolean = true //Endless list\n+\n+      override fun fetchPage(page: Int, pageSize: Int): Single<GhListResponse<User>> =\n+          userService.searchUsers(userName, page = page, pageSize = pageSize)\n+    })\n+","path":"_posts/2018-4-02-XLpaging.md","position":158,"original_position":158,"commit_id":"9c2c8f8feeb9198e87f60e7a2678d8bb2995cf4b","original_commit_id":"9c2c8f8feeb9198e87f60e7a2678d8bb2995cf4b","user":{"login":"bryant1410","id":3905501,"node_id":"MDQ6VXNlcjM5MDU1MDE=","avatar_url":"https://avatars3.githubusercontent.com/u/3905501?v=4","gravatar_id":"","url":"https://api.github.com/users/bryant1410","html_url":"https://github.com/bryant1410","followers_url":"https://api.github.com/users/bryant1410/followers","following_url":"https://api.github.com/users/bryant1410/following{/other_user}","gists_url":"https://api.github.com/users/bryant1410/gists{/gist_id}","starred_url":"https://api.github.com/users/bryant1410/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bryant1410/subscriptions","organizations_url":"https://api.github.com/users/bryant1410/orgs","repos_url":"https://api.github.com/users/bryant1410/repos","events_url":"https://api.github.com/users/bryant1410/events{/privacy}","received_events_url":"https://api.github.com/users/bryant1410/received_events","type":"User","site_admin":false},"body":"remote this line","created_at":"2018-06-12T16:47:22Z","updated_at":"2018-06-12T16:57:30Z","html_url":"https://github.com/xmartlabs/blog/pull/56#discussion_r194811842","pull_request_url":"https://api.github.com/repos/xmartlabs/blog/pulls/56","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/xmartlabs/blog/pulls/comments/194811842"},"html":{"href":"https://github.com/xmartlabs/blog/pull/56#discussion_r194811842"},"pull_request":{"href":"https://api.github.com/repos/xmartlabs/blog/pulls/56"}}},"pull_request":{"url":"https://api.github.com/repos/xmartlabs/blog/pulls/56","id":193703189,"node_id":"MDExOlB1bGxSZXF1ZXN0MTkzNzAzMTg5","html_url":"https://github.com/xmartlabs/blog/pull/56","diff_url":"https://github.com/xmartlabs/blog/pull/56.diff","patch_url":"https://github.com/xmartlabs/blog/pull/56.patch","issue_url":"https://api.github.com/repos/xmartlabs/blog/issues/56","number":56,"state":"open","locked":false,"title":"Android Paging for mortals (part one)","user":{"login":"matir91","id":8472881,"node_id":"MDQ6VXNlcjg0NzI4ODE=","avatar_url":"https://avatars2.githubusercontent.com/u/8472881?v=4","gravatar_id":"","url":"https://api.github.com/users/matir91","html_url":"https://github.com/matir91","followers_url":"https://api.github.com/users/matir91/followers","following_url":"https://api.github.com/users/matir91/following{/other_user}","gists_url":"https://api.github.com/users/matir91/gists{/gist_id}","starred_url":"https://api.github.com/users/matir91/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matir91/subscriptions","organizations_url":"https://api.github.com/users/matir91/orgs","repos_url":"https://api.github.com/users/matir91/repos","events_url":"https://api.github.com/users/matir91/events{/privacy}","received_events_url":"https://api.github.com/users/matir91/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-06-08T19:27:11Z","updated_at":"2018-06-12T16:57:31Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9345f55279ef06e6fdb17c10eee472f54d1913e3","assignee":null,"assignees":[],"requested_reviewers":[{"login":"FerrariBruno","id":13987465,"node_id":"MDQ6VXNlcjEzOTg3NDY1","avatar_url":"https://avatars3.githubusercontent.com/u/13987465?v=4","gravatar_id":"","url":"https://api.github.com/users/FerrariBruno","html_url":"https://github.com/FerrariBruno","followers_url":"https://api.github.com/users/FerrariBruno/followers","following_url":"https://api.github.com/users/FerrariBruno/following{/other_user}","gists_url":"https://api.github.com/users/FerrariBruno/gists{/gist_id}","starred_url":"https://api.github.com/users/FerrariBruno/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FerrariBruno/subscriptions","organizations_url":"https://api.github.com/users/FerrariBruno/orgs","repos_url":"https://api.github.com/users/FerrariBruno/repos","events_url":"https://api.github.com/users/FerrariBruno/events{/privacy}","received_events_url":"https://api.github.com/users/FerrariBruno/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/xmartlabs/blog/pulls/56/commits","review_comments_url":"https://api.github.com/repos/xmartlabs/blog/pulls/56/comments","review_comment_url":"https://api.github.com/repos/xmartlabs/blog/pulls/comments{/number}","comments_url":"https://api.github.com/repos/xmartlabs/blog/issues/56/comments","statuses_url":"https://api.github.com/repos/xmartlabs/blog/statuses/9c2c8f8feeb9198e87f60e7a2678d8bb2995cf4b","head":{"label":"xmartlabs:blog/paging-for-mortals","ref":"blog/paging-for-mortals","sha":"9c2c8f8feeb9198e87f60e7a2678d8bb2995cf4b","user":{"login":"xmartlabs","id":2227731,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyMjc3MzE=","avatar_url":"https://avatars0.githubusercontent.com/u/2227731?v=4","gravatar_id":"","url":"https://api.github.com/users/xmartlabs","html_url":"https://github.com/xmartlabs","followers_url":"https://api.github.com/users/xmartlabs/followers","following_url":"https://api.github.com/users/xmartlabs/following{/other_user}","gists_url":"https://api.github.com/users/xmartlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/xmartlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xmartlabs/subscriptions","organizations_url":"https://api.github.com/users/xmartlabs/orgs","repos_url":"https://api.github.com/users/xmartlabs/repos","events_url":"https://api.github.com/users/xmartlabs/events{/privacy}","received_events_url":"https://api.github.com/users/xmartlabs/received_events","type":"Organization","site_admin":false},"repo":{"id":31186390,"node_id":"MDEwOlJlcG9zaXRvcnkzMTE4NjM5MA==","name":"blog","full_name":"xmartlabs/blog","owner":{"login":"xmartlabs","id":2227731,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyMjc3MzE=","avatar_url":"https://avatars0.githubusercontent.com/u/2227731?v=4","gravatar_id":"","url":"https://api.github.com/users/xmartlabs","html_url":"https://github.com/xmartlabs","followers_url":"https://api.github.com/users/xmartlabs/followers","following_url":"https://api.github.com/users/xmartlabs/following{/other_user}","gists_url":"https://api.github.com/users/xmartlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/xmartlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xmartlabs/subscriptions","organizations_url":"https://api.github.com/users/xmartlabs/orgs","repos_url":"https://api.github.com/users/xmartlabs/repos","events_url":"https://api.github.com/users/xmartlabs/events{/privacy}","received_events_url":"https://api.github.com/users/xmartlabs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/xmartlabs/blog","description":"Xmartlabs Blog","fork":false,"url":"https://api.github.com/repos/xmartlabs/blog","forks_url":"https://api.github.com/repos/xmartlabs/blog/forks","keys_url":"https://api.github.com/repos/xmartlabs/blog/keys{/key_id}","collaborators_url":"https://api.github.com/repos/xmartlabs/blog/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/xmartlabs/blog/teams","hooks_url":"https://api.github.com/repos/xmartlabs/blog/hooks","issue_events_url":"https://api.github.com/repos/xmartlabs/blog/issues/events{/number}","events_url":"https://api.github.com/repos/xmartlabs/blog/events","assignees_url":"https://api.github.com/repos/xmartlabs/blog/assignees{/user}","branches_url":"https://api.github.com/repos/xmartlabs/blog/branches{/branch}","tags_url":"https://api.github.com/repos/xmartlabs/blog/tags","blobs_url":"https://api.github.com/repos/xmartlabs/blog/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/xmartlabs/blog/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/xmartlabs/blog/git/refs{/sha}","trees_url":"https://api.github.com/repos/xmartlabs/blog/git/trees{/sha}","statuses_url":"https://api.github.com/repos/xmartlabs/blog/statuses/{sha}","languages_url":"https://api.github.com/repos/xmartlabs/blog/languages","stargazers_url":"https://api.github.com/repos/xmartlabs/blog/stargazers","contributors_url":"https://api.github.com/repos/xmartlabs/blog/contributors","subscribers_url":"https://api.github.com/repos/xmartlabs/blog/subscribers","subscription_url":"https://api.github.com/repos/xmartlabs/blog/subscription","commits_url":"https://api.github.com/repos/xmartlabs/blog/commits{/sha}","git_commits_url":"https://api.github.com/repos/xmartlabs/blog/git/commits{/sha}","comments_url":"https://api.github.com/repos/xmartlabs/blog/comments{/number}","issue_comment_url":"https://api.github.com/repos/xmartlabs/blog/issues/comments{/number}","contents_url":"https://api.github.com/repos/xmartlabs/blog/contents/{+path}","compare_url":"https://api.github.com/repos/xmartlabs/blog/compare/{base}...{head}","merges_url":"https://api.github.com/repos/xmartlabs/blog/merges","archive_url":"https://api.github.com/repos/xmartlabs/blog/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/xmartlabs/blog/downloads","issues_url":"https://api.github.com/repos/xmartlabs/blog/issues{/number}","pulls_url":"https://api.github.com/repos/xmartlabs/blog/pulls{/number}","milestones_url":"https://api.github.com/repos/xmartlabs/blog/milestones{/number}","notifications_url":"https://api.github.com/repos/xmartlabs/blog/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/xmartlabs/blog/labels{/name}","releases_url":"https://api.github.com/repos/xmartlabs/blog/releases{/id}","deployments_url":"https://api.github.com/repos/xmartlabs/blog/deployments","created_at":"2015-02-22T23:40:28Z","updated_at":"2018-03-29T16:57:19Z","pushed_at":"2018-06-12T16:38:28Z","git_url":"git://github.com/xmartlabs/blog.git","ssh_url":"git@github.com:xmartlabs/blog.git","clone_url":"https://github.com/xmartlabs/blog.git","svn_url":"https://github.com/xmartlabs/blog","homepage":"https://blog.xmartlabs.com","size":27476,"stargazers_count":10,"watchers_count":10,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":5,"license":null,"forks":5,"open_issues":5,"watchers":10,"default_branch":"master"}},"base":{"label":"xmartlabs:master","ref":"master","sha":"48a5c6a3fc595273ee4af4762f722787c42aa097","user":{"login":"xmartlabs","id":2227731,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyMjc3MzE=","avatar_url":"https://avatars0.githubusercontent.com/u/2227731?v=4","gravatar_id":"","url":"https://api.github.com/users/xmartlabs","html_url":"https://github.com/xmartlabs","followers_url":"https://api.github.com/users/xmartlabs/followers","following_url":"https://api.github.com/users/xmartlabs/following{/other_user}","gists_url":"https://api.github.com/users/xmartlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/xmartlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xmartlabs/subscriptions","organizations_url":"https://api.github.com/users/xmartlabs/orgs","repos_url":"https://api.github.com/users/xmartlabs/repos","events_url":"https://api.github.com/users/xmartlabs/events{/privacy}","received_events_url":"https://api.github.com/users/xmartlabs/received_events","type":"Organization","site_admin":false},"repo":{"id":31186390,"node_id":"MDEwOlJlcG9zaXRvcnkzMTE4NjM5MA==","name":"blog","full_name":"xmartlabs/blog","owner":{"login":"xmartlabs","id":2227731,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIyMjc3MzE=","avatar_url":"https://avatars0.githubusercontent.com/u/2227731?v=4","gravatar_id":"","url":"https://api.github.com/users/xmartlabs","html_url":"https://github.com/xmartlabs","followers_url":"https://api.github.com/users/xmartlabs/followers","following_url":"https://api.github.com/users/xmartlabs/following{/other_user}","gists_url":"https://api.github.com/users/xmartlabs/gists{/gist_id}","starred_url":"https://api.github.com/users/xmartlabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xmartlabs/subscriptions","organizations_url":"https://api.github.com/users/xmartlabs/orgs","repos_url":"https://api.github.com/users/xmartlabs/repos","events_url":"https://api.github.com/users/xmartlabs/events{/privacy}","received_events_url":"https://api.github.com/users/xmartlabs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/xmartlabs/blog","description":"Xmartlabs Blog","fork":false,"url":"https://api.github.com/repos/xmartlabs/blog","forks_url":"https://api.github.com/repos/xmartlabs/blog/forks","keys_url":"https://api.github.com/repos/xmartlabs/blog/keys{/key_id}","collaborators_url":"https://api.github.com/repos/xmartlabs/blog/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/xmartlabs/blog/teams","hooks_url":"https://api.github.com/repos/xmartlabs/blog/hooks","issue_events_url":"https://api.github.com/repos/xmartlabs/blog/issues/events{/number}","events_url":"https://api.github.com/repos/xmartlabs/blog/events","assignees_url":"https://api.github.com/repos/xmartlabs/blog/assignees{/user}","branches_url":"https://api.github.com/repos/xmartlabs/blog/branches{/branch}","tags_url":"https://api.github.com/repos/xmartlabs/blog/tags","blobs_url":"https://api.github.com/repos/xmartlabs/blog/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/xmartlabs/blog/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/xmartlabs/blog/git/refs{/sha}","trees_url":"https://api.github.com/repos/xmartlabs/blog/git/trees{/sha}","statuses_url":"https://api.github.com/repos/xmartlabs/blog/statuses/{sha}","languages_url":"https://api.github.com/repos/xmartlabs/blog/languages","stargazers_url":"https://api.github.com/repos/xmartlabs/blog/stargazers","contributors_url":"https://api.github.com/repos/xmartlabs/blog/contributors","subscribers_url":"https://api.github.com/repos/xmartlabs/blog/subscribers","subscription_url":"https://api.github.com/repos/xmartlabs/blog/subscription","commits_url":"https://api.github.com/repos/xmartlabs/blog/commits{/sha}","git_commits_url":"https://api.github.com/repos/xmartlabs/blog/git/commits{/sha}","comments_url":"https://api.github.com/repos/xmartlabs/blog/comments{/number}","issue_comment_url":"https://api.github.com/repos/xmartlabs/blog/issues/comments{/number}","contents_url":"https://api.github.com/repos/xmartlabs/blog/contents/{+path}","compare_url":"https://api.github.com/repos/xmartlabs/blog/compare/{base}...{head}","merges_url":"https://api.github.com/repos/xmartlabs/blog/merges","archive_url":"https://api.github.com/repos/xmartlabs/blog/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/xmartlabs/blog/downloads","issues_url":"https://api.github.com/repos/xmartlabs/blog/issues{/number}","pulls_url":"https://api.github.com/repos/xmartlabs/blog/pulls{/number}","milestones_url":"https://api.github.com/repos/xmartlabs/blog/milestones{/number}","notifications_url":"https://api.github.com/repos/xmartlabs/blog/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/xmartlabs/blog/labels{/name}","releases_url":"https://api.github.com/repos/xmartlabs/blog/releases{/id}","deployments_url":"https://api.github.com/repos/xmartlabs/blog/deployments","created_at":"2015-02-22T23:40:28Z","updated_at":"2018-03-29T16:57:19Z","pushed_at":"2018-06-12T16:38:28Z","git_url":"git://github.com/xmartlabs/blog.git","ssh_url":"git@github.com:xmartlabs/blog.git","clone_url":"https://github.com/xmartlabs/blog.git","svn_url":"https://github.com/xmartlabs/blog","homepage":"https://blog.xmartlabs.com","size":27476,"stargazers_count":10,"watchers_count":10,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":5,"license":null,"forks":5,"open_issues":5,"watchers":10,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/xmartlabs/blog/pulls/56"},"html":{"href":"https://github.com/xmartlabs/blog/pull/56"},"issue":{"href":"https://api.github.com/repos/xmartlabs/blog/issues/56"},"comments":{"href":"https://api.github.com/repos/xmartlabs/blog/issues/56/comments"},"review_comments":{"href":"https://api.github.com/repos/xmartlabs/blog/pulls/56/comments"},"review_comment":{"href":"https://api.github.com/repos/xmartlabs/blog/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/xmartlabs/blog/pulls/56/commits"},"statuses":{"href":"https://api.github.com/repos/xmartlabs/blog/statuses/9c2c8f8feeb9198e87f60e7a2678d8bb2995cf4b"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"bryant1410"}}