Skip to content

Commit

Permalink
πŸ“š Add new indexer documents for Lens v3: v3 (#indexer-codegen)
Browse files Browse the repository at this point in the history
Summary: Added new GraphQL mutation documents for account operations.

Highlights:

β€’ Introduced `Block.graphql` and `Unblock.graphql` for account blocking/unblocking.
β€’ Added `CreateAccountWithUsername.graphql` for account creation with username.
β€’ Updated `Follow.graphql` and `Unfollow.graphql` to include detailed transaction reasons.

Read more: https://pierre.co/hey/hey/indexer-codegen
  • Loading branch information
Yoginth authored and Pierre committed Nov 26, 2024
1 parent ae45b9a commit 1113c34
Show file tree
Hide file tree
Showing 6 changed files with 255 additions and 32 deletions.
16 changes: 16 additions & 0 deletions packages/indexer/documents/mutations/account/Block.graphql
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
mutation Block($request: BlockRequest!) {
block(request: $request) {
... on BlockResponse {
hash
}
... on BlockError {
error
}
... on SelfFundedTransactionRequest {
selfFundedReason: reason
}
... on SponsoredTransactionRequest {
sponsoredReason: reason
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
mutation CreateAccountWithUsername(
$request: CreateAccountWithUsernameRequest!
) {
createAccountWithUsername(request: $request) {
... on CreateAccountResponse {
hash
}
... on InvalidUsername {
invalidUsernameReason: reason
}
... on SelfFundedTransactionRequest {
selfFundedReason: reason
}
... on SponsoredTransactionRequest {
sponsoredReason: reason
}
... on TransactionWillFail {
transactionFailReason: reason
}
}
}
32 changes: 16 additions & 16 deletions packages/indexer/documents/mutations/account/Follow.graphql
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# mutation Follow($request: CreateFollowRequest!) {
# follow(request: $request) {
# ... on FollowResponse {
# hash
# }
# ... on SelfFundedTransactionRequest {
# reason
# }
# ... on SponsoredTransactionRequest {
# reason
# }
# ... on TransactionWillFail {
# reason
# }
# }
# }
mutation Follow($request: CreateFollowRequest!) {
follow(request: $request) {
... on FollowResponse {
hash
}
... on SelfFundedTransactionRequest {
selfFundedReason: reason
}
... on SponsoredTransactionRequest {
sponsoredReason: reason
}
... on TransactionWillFail {
transactionFailReason: reason
}
}
}
16 changes: 16 additions & 0 deletions packages/indexer/documents/mutations/account/Unblock.graphql
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
mutation Unblock($request: UnblockRequest!) {
unblock(request: $request) {
... on UnblockResponse {
hash
}
... on UnblockError {
error
}
... on SelfFundedTransactionRequest {
selfFundedReason: reason
}
... on SponsoredTransactionRequest {
sponsoredReason: reason
}
}
}
32 changes: 16 additions & 16 deletions packages/indexer/documents/mutations/account/Unfollow.graphql
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# mutation Unfollow($request: CreateUnfollowRequest!) {
# unfollow(request: $request) {
# ... on UnfollowResponse {
# hash
# }
# ... on SelfFundedTransactionRequest {
# reason
# }
# ... on SponsoredTransactionRequest {
# reason
# }
# ... on TransactionWillFail {
# reason
# }
# }
# }
mutation Unfollow($request: CreateUnfollowRequest!) {
unfollow(request: $request) {
... on UnfollowResponse {
hash
}
... on SelfFundedTransactionRequest {
selfFundedReason: reason
}
... on SponsoredTransactionRequest {
sponsoredReason: reason
}
... on TransactionWillFail {
transactionFailReason: reason
}
}
}
Loading

1 comment on commit 1113c34

@vercel
Copy link

@vercel vercel bot commented on 1113c34 Nov 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

web – ./

web-git-main-heyxyz.vercel.app
web-heyxyz.vercel.app
heyxyz.vercel.app
hey.xyz

Please sign in to comment.