Added Directus System Endpoint and displaying files
This commit is contained in:
8
.wundergraph/operations/Files.graphql
Normal file
8
.wundergraph/operations/Files.graphql
Normal file
@ -0,0 +1,8 @@
|
||||
query {
|
||||
system_db_files {
|
||||
id
|
||||
title
|
||||
type
|
||||
filename_disk
|
||||
}
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
query Projects {
|
||||
directus_projects {
|
||||
query {
|
||||
db_projects {
|
||||
id
|
||||
text
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
query Todos {
|
||||
directus_todos {
|
||||
query {
|
||||
db_todos {
|
||||
id
|
||||
task
|
||||
user_created {
|
||||
|
@ -6,15 +6,20 @@ export default createOperation.query({
|
||||
address: z.string(),
|
||||
}),
|
||||
handler: async ({ input }) => {
|
||||
console.log('Making request with input:', input); // Log the input
|
||||
|
||||
const { data } = await axios.get('https://api.gnosisscan.io/api', {
|
||||
params: {
|
||||
module: 'account',
|
||||
action: 'balance',
|
||||
address: input.address,
|
||||
tag: 'latest',
|
||||
apikey: process.env.GNOSISSCAN_API,
|
||||
// tag: 'latest',
|
||||
// apikey: process.env.GNOSISSCAN_API,
|
||||
},
|
||||
timeout: 10000,
|
||||
});
|
||||
|
||||
console.log('Received response:', data);
|
||||
return {
|
||||
balance: parseFloat(data.result),
|
||||
};
|
||||
|
@ -1,5 +1,5 @@
|
||||
query Bookmarks {
|
||||
directus_bookmarks {
|
||||
query {
|
||||
db_bookmarks {
|
||||
id
|
||||
name
|
||||
url
|
||||
|
Reference in New Issue
Block a user