Skip to content

IssueEvent misses important properties #302

Description

@nomeata

Consider

$ curl -u nomeata:TOKEN https://api.github.com/repos/ghc-proposals/ghc-proposals/issues/51/events
[
  {
    "id": 1096640569,
    "url": "https://api.github.com/repos/ghc-proposals/ghc-proposals/issues/events/1096640569",
    "actor": {
      "login": "nomeata",
      "id": 148037,
      "avatar_url": "https://avatars2.githubusercontent.com/u/148037?v=4",
      "gravatar_id": "",
      "url": "https://api.github.com/users/nomeata",
      "html_url": "https://github.com/nomeata",
      "followers_url": "https://api.github.com/users/nomeata/followers",
      "following_url": "https://api.github.com/users/nomeata/following{/other_user}",
      "gists_url": "https://api.github.com/users/nomeata/gists{/gist_id}",
      "starred_url": "https://api.github.com/users/nomeata/starred{/owner}{/repo}",
      "subscriptions_url": "https://api.github.com/users/nomeata/subscriptions",
      "organizations_url": "https://api.github.com/users/nomeata/orgs",
      "repos_url": "https://api.github.com/users/nomeata/repos",
      "events_url": "https://api.github.com/users/nomeata/events{/privacy}",
      "received_events_url": "https://api.github.com/users/nomeata/received_events",
      "type": "User",
      "site_admin": false
    },
    "event": "labeled",
    "commit_id": null,
    "commit_url": null,
    "created_at": "2017-05-25T02:16:56Z",
    "label": {
      "name": "dormant",
      "color": "aadddd"
    }
  }
]

The important information is in the optional label attribute. But github does not include that:

[IssueEvent {issueEventActor = SimpleUser {simpleUserId = Id 148037, simpleUserLogin = N "nomeata", simpleUserAvatarUrl = URL "https://avatars2.githubusercontent.com/u/148037?v=4", simpleUserUrl = URL "https://api.github.com/users/nomeata"}, issueEventType = Labeled, issueEventCommitId = Nothing, issueEventUrl = URL "https://api.github.com/repos/ghc-proposals/ghc-proposals/issues/events/1096640569", issueEventCreatedAt = 2017-05-25 02:16:56 UTC, issueEventId = 1096640569, issueEventIssue = Nothing}]

Is there a way I could get hold of the label using the github bindings?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions