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

Document how to follow and unfollow using snapshot.js #562

Open
nischitpra opened this issue Mar 29, 2022 · 5 comments
Open

Document how to follow and unfollow using snapshot.js #562

nischitpra opened this issue Mar 29, 2022 · 5 comments
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request

Comments

@nischitpra
Copy link

nischitpra commented Mar 29, 2022

Is your feature request related to a problem? Please describe.

  1. I need to search list of spaces by user account address
  2. I need to create and join spaces using snapshot.js but the documentation only has a placeholder .... When will the api be ready?

Describe the solution you'd like
await client.spaces.get("client account address")
await client.spaces.create("awesome.eth", "client account address")
await client.spaces.join("awesome.eth", "client account address")

Additional context
The graphql query for multiple spaces doesn't allow searching by members. Can add there as well.

@nischitpra nischitpra changed the title Get spaces where user is a member of Get/Create/Join spaces by user account address Mar 29, 2022
@mktcode
Copy link
Contributor

mktcode commented Mar 29, 2022

@ChaituVR Should this issue be transferred to snapshot.js repo?

@nischitpra
Copy link
Author

@mktcode Hey, I wanted to know if this will be picked?

@ChaituVR
Copy link
Member

ChaituVR commented Apr 5, 2022

Oh, sorry guys I missed this somehow, so

  1. I need to search the list of spaces by user account address

For this, you can use graphQL API, and query like this:

query follows {
  follows (where:{follower: "<ADDRESS>"}) {
    follower
    space {
      id
    }
  }
}
  1. I need to create and join spaces using snapshot.js but the documentation only has a placeholder .... When will the api be ready?
    Describe the solution you'd like
    await client.spaces.get("client account address")
    await client.spaces.create("awesome.eth", "client account address")
    await client.spaces.join("awesome.eth", "client account address")

Should confirm with @bonustrack as there might be a reason for not adding this, this needs an alias address and maybe users can spam it easily?

@ChaituVR ChaituVR transferred this issue from snapshot-labs/snapshot Apr 20, 2022
@ChaituVR
Copy link
Member

Yes we should document how to follow and unfollow spaces using snapshot.js

@ChaituVR ChaituVR changed the title Get/Create/Join spaces by user account address Document how to follow and unfollow using snapshot.js Apr 20, 2022
@mktcode mktcode added documentation Improvements or additions to documentation enhancement New feature or request labels Apr 20, 2022
@HiperMaximus
Copy link

bump to document this

@ChaituVR ChaituVR assigned zzuziak and unassigned ChaituVR Jun 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants