Carbon-Farm-Network / app-carbon-farm-network

GNU Affero General Public License v3.0
2 stars 0 forks source link

Cleanup dummy data from initial prototype #5

Open pospi opened 1 year ago

pospi commented 1 year ago

I think we can omit Agent editing for now? Though if the form control stuff you're working on already includes the ability to load up the form with existing values then you may as well implement updateAgent while you're here.

The best tips I can give you RE authoring GraphQL API calls are:

  1. Use a GraphiQL query authoring interface that comes with documentation and autocomplete (see below).
  2. There is a test folder in the hREA repo which has many examples you can copy from (for example, updating an Organization).

Unfortunately not all of the hREA test suite uses GraphQL so YMMV in locating particular sample code. An easy way to experiment with query syntax without having to do a lot of setup is to use the mock API provided with the specification. If you need to do "real" testing of your queries where a backend system is persisting and providing data then simply install the latest hREA release into your Holochain launcher and open up the bundled UI.

pospi commented 1 year ago