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

[SG] Adds Group Notifications #8

Merged
merged 3 commits into from
Aug 5, 2022
Merged

Conversation

LaimeJesus
Copy link

related #162

Description

This PR adds the following changes:

  • Adds schemas for new group events data
    • group creation: group address, group name, user safe address (creator)
    • group member added/removed: group address, user safe address (member)
    • group minted: group address, mint amount, fee amount, user safe address (receiver)
  • Adds Group event Data in Notification Schema
  • Adds Handlers to generate notifications with new events

How to test

See deployed SG: https://thegraph.com/hosted-service/subgraph/laimejesus/shisus-crc-local

Group Event Data

{
  groupCreations {
    id,
    group,
    name,
    creator
  }
  
  groupAddMembers {
    id,
    user
  }
  
  groupRemoveMembers {
    id,
    user
  }

  groupMints {
    id,
    amount,
    receiver,
    mintFee
  }
}

Notifcations

{
  notifications(where: {
    safe: "0xb77d3948693b6dee0f85184db515ce4910c21fe9"
  },
    orderBy: time,
    orderDirection: desc) {
    id
    transactionHash
    safeAddress
    type
    time
    trust {
      user
      canSendTo
      limitPercentage
    }
    transfer {
      from
      to
      amount
    }
    hubTransfer {
      from
      to
      amount
    }
    ownership {
      adds
      removes
    }
    groupCreation {
      id
      group
      name
      creator
    }
    groupAddMember {
      id
      user
    }
    groupRemoveMember {
      id
      user
    }
    groupMint {
      id
      amount
      receiver
      mintFee
    }
  }
}

Example

image

image

@LaimeJesus LaimeJesus merged commit 15cb295 into dev Aug 5, 2022
@LaimeJesus LaimeJesus deleted the feature/#162-group-notifications branch August 5, 2022 14:52
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.

2 participants