Skip to content
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

Closes #91: Add a GET endpoint to list filter subscriptions #91

Conversation

fllaca
Copy link
Contributor

@fllaca fllaca commented Oct 17, 2019

Closes #91 . First approach to have an endpoint to list the existing filter subscriptions.

Output:

➜  eventeum git:(master) ✗ curl -XGET -H "Content-Type: application/json" localhost:8060/api/rest/v1/event-filter | jq
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   670    0   670    0     0  44666      0 --:--:-- --:--:-- --:--:-- 44666
[
  {
    "id": "my-custom-event",
    "contractAddress": "0xd6dE21390c5D2045A4f8477133bb9a23ea9c3F88",
    "node": "default",
    "eventSpecification": {
      "eventName": "Mint",
      "indexedParameterDefinitions": [
        {
          "position": 0,
          "type": "ADDRESS"
        }
      ],
      "nonIndexedParameterDefinitions": [
        {
          "position": 1,
          "type": "STRING"
        },
        {
          "position": 2,
          "type": "UINT256"
        }
      ]
    },
    "startBlock": 0
  },
  {
    "id": "a17fd147-1c36-4759-b2a4-024d2ac9f46f",
    "contractAddress": "0xd6dE21390c5A2045A4b8477133bb9a23ea9c3F66",
    "node": "default",
    "eventSpecification": {
      "eventName": "Mint",
      "indexedParameterDefinitions": [
        {
          "position": 0,
          "type": "ADDRESS"
        }
      ],
      "nonIndexedParameterDefinitions": [
        {
          "position": 1,
          "type": "STRING"
        },
        {
          "position": 2,
          "type": "UINT256"
        }
      ]
    },
    "startBlock": 0
  }
]

@fllaca fllaca changed the title Add a GET endpoint to list filter subscriptions Closes #91: Add a GET endpoint to list filter subscriptions Oct 17, 2019
@craigwilliams84
Copy link
Collaborator

Thanks Fernando! Could you also add some documentation for the endpoint in the README? Also, a basic few integration tests (in the server project) could be useful.

@craigwilliams84 craigwilliams84 merged commit 3947c47 into eventeum:development Oct 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants