Skip to content

Instantly share code, notes, and snippets.

@PaulRBerg
Created May 18, 2019 21:47
Apollo query for StackOverflow question
import gql from "graphql-tag";
export const GET_STREAMS = gql`
query Streams($owner: String!) {
streams(orderBy: id, orderDirection: desc, where: { owner: $owner }) {
id
flow
owner
rawStream {
id
interval
payment
recipient
redeemal {
id
recipientAmount
senderAmount
}
sender
startBlock
status
stopBlock
token {
id
decimals
name
symbol
}
txs {
id
}
withdrawals {
id
amount
}
}
}
}
`;
export const GET_STREAM = gql`
query Stream($streamId: ID!) {
stream(id: $streamId) {
id
flow
rawStream {
id
interval
payment
recipient
redeemal {
id
recipientAmount
senderAmount
}
sender
startBlock
status
stopBlock
token {
id
decimals
name
symbol
}
txs {
id
}
withdrawals {
id
amount
}
}
}
}
`;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment