From e0a0cfa3411144bca93e91078c6998ebacf22472 Mon Sep 17 00:00:00 2001 From: steebchen Date: Sat, 9 Nov 2024 00:39:09 +0700 Subject: [PATCH] feat(torii): add config file support for Torii deployments Added optional config_file parameter to Torii deployments. New files read in base64 and included in the deployment request. Updated corresponding GraphQL schema and dependencies. --- .gitignore | 1 + Cargo.lock | 1 + cli/Cargo.toml | 1 + cli/src/command/deployments/create.rs | 52 +- cli/src/command/deployments/services/torii.rs | 7 +- scripts/pull_schema.sh | 4 +- slot/schema.json | 2117 ++++++++++++++++- slot/src/graphql/deployments/create.graphql | 1 + 8 files changed, 2087 insertions(+), 97 deletions(-) diff --git a/.gitignore b/.gitignore index ea8c4bf..2ed13c4 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /target +torii.toml diff --git a/Cargo.lock b/Cargo.lock index 66647b7..51fe91b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -4309,6 +4309,7 @@ version = "0.21.0" dependencies = [ "anyhow", "axum", + "base64 0.21.7", "clap", "ctrlc", "dialoguer", diff --git a/cli/Cargo.toml b/cli/Cargo.toml index f9efa70..ebc48cd 100644 --- a/cli/Cargo.toml +++ b/cli/Cargo.toml @@ -27,6 +27,7 @@ starknet.workspace = true shellexpand = "3.1.0" url.workspace = true rand.workspace = true +base64 = "0.21.7" [[bin]] name = "slot" diff --git a/cli/src/command/deployments/create.rs b/cli/src/command/deployments/create.rs index ff4fbf3..d44119e 100644 --- a/cli/src/command/deployments/create.rs +++ b/cli/src/command/deployments/create.rs @@ -1,6 +1,7 @@ #![allow(clippy::enum_variant_names)] use anyhow::Result; +use base64::encode; use clap::Args; use slot::api::Client; use slot::credential::Credentials; @@ -10,6 +11,7 @@ use slot::graphql::deployments::create_deployment::CreateDeploymentCreateDeploym use slot::graphql::deployments::create_deployment::*; use slot::graphql::deployments::CreateDeployment; use slot::graphql::GraphQLQuery; +use std::fs; use super::{services::CreateServiceCommands, Tier}; @@ -61,24 +63,40 @@ impl CreateArgs { saya: None, }), }, - CreateServiceCommands::Torii(config) => CreateServiceInput { - type_: DeploymentService::torii, - version: config.version.clone(), - config: Some(CreateServiceConfigInput { - katana: None, - torii: Some(CreateToriiConfigInput { - rpc: Some(config.rpc.clone().unwrap_or("".to_string())), - world: format!("{:#x}", config.world), - contracts: config.contracts.clone(), - start_block: config.start_block, - index_pending: config.index_pending, - polling_interval: config.polling_interval, - index_transactions: config.index_transactions, - index_raw_events: config.index_raw_events, + CreateServiceCommands::Torii(config) => { + // Read the file and convert to base64 + let config_file_base64 = match &config.config_file { + Some(file_path) => { + let file_contents = fs::read(file_path)?; + Some(encode(&file_contents)) + } + None => None, + }; + + CreateServiceInput { + type_: DeploymentService::torii, + version: config.version.clone(), + config: Some(CreateServiceConfigInput { + katana: None, + torii: Some(CreateToriiConfigInput { + rpc: Some(config.rpc.clone().unwrap_or("".to_string())), + // provide world if provided + world: match &config.world { + Some(world) => format!("{:#x}", world).into(), + None => None, + }, + contracts: config.contracts.clone(), + start_block: config.start_block, + index_pending: config.index_pending, + polling_interval: config.polling_interval, + index_transactions: config.index_transactions, + index_raw_events: config.index_raw_events, + config_file: config_file_base64, + }), + saya: None, }), - saya: None, - }), - }, + } + } CreateServiceCommands::Saya(config) => CreateServiceInput { type_: DeploymentService::saya, version: config.version.clone(), diff --git a/cli/src/command/deployments/services/torii.rs b/cli/src/command/deployments/services/torii.rs index 6414e16..f3b074f 100644 --- a/cli/src/command/deployments/services/torii.rs +++ b/cli/src/command/deployments/services/torii.rs @@ -16,7 +16,12 @@ pub struct ToriiCreateArgs { #[arg(long)] #[arg(value_name = "world")] #[arg(help = "World address.")] - pub world: Felt, + pub world: Option, + + #[arg(long)] + #[arg(help = "A config file ")] + #[arg(value_name = "config-file")] + pub config_file: Option, #[arg(short, long)] #[arg(value_name = "contracts")] diff --git a/scripts/pull_schema.sh b/scripts/pull_schema.sh index 2edb3b1..8bfd18c 100755 --- a/scripts/pull_schema.sh +++ b/scripts/pull_schema.sh @@ -3,5 +3,5 @@ # https://github.com/graphql-rust/graphql-client/blob/main/graphql_client_cli/README.md # cargo install graphql_client_cli -graphql-client introspect-schema --output slot/schema.json https://api.cartridge.gg/query -# graphql-client introspect-schema --output slot/schema.json http://localhost:8000/query +#graphql-client introspect-schema --output slot/schema.json https://api.cartridge.gg/query +graphql-client introspect-schema --output slot/schema.json http://localhost:8000/query diff --git a/slot/schema.json b/slot/schema.json index 85bf6ce..ae2cad9 100644 --- a/slot/schema.json +++ b/slot/schema.json @@ -455,6 +455,83 @@ } } }, + { + "args": [ + { + "defaultValue": null, + "description": "Returns the elements in the list that come after the specified cursor.", + "name": "after", + "type": { + "kind": "SCALAR", + "name": "Cursor", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Returns the first _n_ elements from the list.", + "name": "first", + "type": { + "kind": "SCALAR", + "name": "Int", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Returns the elements in the list that come before the specified cursor.", + "name": "before", + "type": { + "kind": "SCALAR", + "name": "Cursor", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Returns the last _n_ elements from the list.", + "name": "last", + "type": { + "kind": "SCALAR", + "name": "Int", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Ordering options for Activities returned from the connection.", + "name": "orderBy", + "type": { + "kind": "INPUT_OBJECT", + "name": "ActivityOrder", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Filtering options for Activities returned from the connection.", + "name": "where", + "type": { + "kind": "INPUT_OBJECT", + "name": "ActivityWhereInput", + "ofType": null + } + } + ], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "activities", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "OBJECT", + "name": "ActivityConnection", + "ofType": null + } + } + }, { "args": [ { @@ -1414,7 +1491,1761 @@ { "defaultValue": null, "description": null, - "name": "nameHasPrefix", + "name": "nameHasPrefix", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "nameHasSuffix", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "nameIsNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "nameNotNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "nameEqualFold", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "nameContainsFold", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "username field predicates", + "name": "username", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameNEQ", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameGT", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameGTE", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameLT", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameLTE", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameContains", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameHasPrefix", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameHasSuffix", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameEqualFold", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "usernameContainsFold", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "created_at field predicates", + "name": "createdAt", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "createdAtNEQ", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "createdAtIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "createdAtNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "createdAtGT", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "createdAtGTE", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "createdAtLT", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "createdAtLTE", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "updated_at field predicates", + "name": "updatedAt", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "updatedAtNEQ", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "updatedAtIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "updatedAtNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "updatedAtGT", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "updatedAtGTE", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "updatedAtLT", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "updatedAtLTE", + "type": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "teams edge predicates", + "name": "hasTeams", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "hasTeamsWith", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "INPUT_OBJECT", + "name": "TeamWhereInput", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": "controllers edge predicates", + "name": "hasControllers", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "hasControllersWith", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "INPUT_OBJECT", + "name": "ControllerWhereInput", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": "activities edge predicates", + "name": "hasActivities", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "hasActivitiesWith", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "INPUT_OBJECT", + "name": "ActivityWhereInput", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": "membership edge predicates", + "name": "hasMembership", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "hasMembershipWith", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "INPUT_OBJECT", + "name": "AccountTeamWhereInput", + "ofType": null + } + } + } + } + ], + "interfaces": [], + "kind": "INPUT_OBJECT", + "name": "AccountWhereInput", + "possibleTypes": [] + }, + { + "description": null, + "enumValues": [], + "fields": [ + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "id", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "accountID", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "controllerID", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "args": [], + "deprecationReason": null, + "description": "Type of activity", + "isDeprecated": false, + "name": "type", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "ActivityType", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": "Status of the activity", + "isDeprecated": false, + "name": "status", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "ActivityStatus", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": "Blockchain network if applicable", + "isDeprecated": false, + "name": "network", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "args": [], + "deprecationReason": null, + "description": "Transaction hash if this is a blockchain transaction", + "isDeprecated": false, + "name": "transactionHash", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "args": [], + "deprecationReason": null, + "description": "Additional activity details in JSON format", + "isDeprecated": false, + "name": "details", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "createdAt", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "updatedAt", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Time", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "account", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "OBJECT", + "name": "Account", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "controller", + "type": { + "kind": "OBJECT", + "name": "Controller", + "ofType": null + } + } + ], + "inputFields": [], + "interfaces": [ + { + "kind": "INTERFACE", + "name": "Node", + "ofType": null + } + ], + "kind": "OBJECT", + "name": "Activity", + "possibleTypes": [] + }, + { + "description": "A connection to a list of items.", + "enumValues": [], + "fields": [ + { + "args": [], + "deprecationReason": null, + "description": "A list of edges.", + "isDeprecated": false, + "name": "edges", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "OBJECT", + "name": "ActivityEdge", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": "Information to aid in pagination.", + "isDeprecated": false, + "name": "pageInfo", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "OBJECT", + "name": "PageInfo", + "ofType": null + } + } + }, + { + "args": [], + "deprecationReason": null, + "description": "Identifies the total count of items in the connection.", + "isDeprecated": false, + "name": "totalCount", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Int", + "ofType": null + } + } + } + ], + "inputFields": [], + "interfaces": [], + "kind": "OBJECT", + "name": "ActivityConnection", + "possibleTypes": [] + }, + { + "description": "An edge in a connection.", + "enumValues": [], + "fields": [ + { + "args": [], + "deprecationReason": null, + "description": "The item at the end of the edge.", + "isDeprecated": false, + "name": "node", + "type": { + "kind": "OBJECT", + "name": "Activity", + "ofType": null + } + }, + { + "args": [], + "deprecationReason": null, + "description": "A cursor for use in pagination.", + "isDeprecated": false, + "name": "cursor", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Cursor", + "ofType": null + } + } + } + ], + "inputFields": [], + "interfaces": [], + "kind": "OBJECT", + "name": "ActivityEdge", + "possibleTypes": [] + }, + { + "description": "Ordering options for Activity connections", + "enumValues": [], + "fields": [], + "inputFields": [ + { + "defaultValue": "ASC", + "description": "The ordering direction.", + "name": "direction", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "OrderDirection", + "ofType": null + } + } + }, + { + "defaultValue": null, + "description": "The field by which to order Activities.", + "name": "field", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "ActivityOrderField", + "ofType": null + } + } + } + ], + "interfaces": [], + "kind": "INPUT_OBJECT", + "name": "ActivityOrder", + "possibleTypes": [] + }, + { + "description": "Properties by which Activity connections can be ordered.", + "enumValues": [ + { + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "CREATED_AT" + } + ], + "fields": [], + "inputFields": [], + "interfaces": [], + "kind": "ENUM", + "name": "ActivityOrderField", + "possibleTypes": [] + }, + { + "description": "ActivityStatus is enum for the field status", + "enumValues": [ + { + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "PENDING" + }, + { + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "COMPLETED" + }, + { + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "FAILED" + } + ], + "fields": [], + "inputFields": [], + "interfaces": [], + "kind": "ENUM", + "name": "ActivityStatus", + "possibleTypes": [] + }, + { + "description": "ActivityType is enum for the field type", + "enumValues": [ + { + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "TRANSACTION" + }, + { + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "SESSION_CREATED" + } + ], + "fields": [], + "inputFields": [], + "interfaces": [], + "kind": "ENUM", + "name": "ActivityType", + "possibleTypes": [] + }, + { + "description": "ActivityWhereInput is used for filtering Activity objects.\nInput was generated by ent.", + "enumValues": [], + "fields": [], + "inputFields": [ + { + "defaultValue": null, + "description": null, + "name": "not", + "type": { + "kind": "INPUT_OBJECT", + "name": "ActivityWhereInput", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "and", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "INPUT_OBJECT", + "name": "ActivityWhereInput", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "or", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "INPUT_OBJECT", + "name": "ActivityWhereInput", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": "id field predicates", + "name": "id", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "idNEQ", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "idIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "idNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "idGT", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "idGTE", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "idLT", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "idLTE", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "account_id field predicates", + "name": "accountID", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDNEQ", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDGT", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDGTE", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDLT", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDLTE", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDContains", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDHasPrefix", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDHasSuffix", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDEqualFold", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "accountIDContainsFold", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "controller_id field predicates", + "name": "controllerID", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDNEQ", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDGT", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDGTE", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDLT", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDLTE", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDContains", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDHasPrefix", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDHasSuffix", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDIsNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDNotNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDEqualFold", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "controllerIDContainsFold", + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "type field predicates", + "name": "type", + "type": { + "kind": "ENUM", + "name": "ActivityType", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "typeNEQ", + "type": { + "kind": "ENUM", + "name": "ActivityType", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "typeIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "ActivityType", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "typeNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "ActivityType", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": "status field predicates", + "name": "status", + "type": { + "kind": "ENUM", + "name": "ActivityStatus", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "statusNEQ", + "type": { + "kind": "ENUM", + "name": "ActivityStatus", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "statusIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "ActivityStatus", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "statusNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "ENUM", + "name": "ActivityStatus", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": "network field predicates", + "name": "network", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkNEQ", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkGT", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkGTE", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkLT", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkLTE", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkContains", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkHasPrefix", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkHasSuffix", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkIsNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkNotNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkEqualFold", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "networkContainsFold", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "transaction_hash field predicates", + "name": "transactionHash", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashNEQ", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashNotIn", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + } + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashGT", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashGTE", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashLT", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashLTE", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashContains", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "transactionHashHasPrefix", "type": { "kind": "SCALAR", "name": "String", @@ -1424,7 +3255,7 @@ { "defaultValue": null, "description": null, - "name": "nameHasSuffix", + "name": "transactionHashHasSuffix", "type": { "kind": "SCALAR", "name": "String", @@ -1434,7 +3265,7 @@ { "defaultValue": null, "description": null, - "name": "nameIsNil", + "name": "transactionHashIsNil", "type": { "kind": "SCALAR", "name": "Boolean", @@ -1444,7 +3275,7 @@ { "defaultValue": null, "description": null, - "name": "nameNotNil", + "name": "transactionHashNotNil", "type": { "kind": "SCALAR", "name": "Boolean", @@ -1454,7 +3285,7 @@ { "defaultValue": null, "description": null, - "name": "nameEqualFold", + "name": "transactionHashEqualFold", "type": { "kind": "SCALAR", "name": "String", @@ -1464,7 +3295,7 @@ { "defaultValue": null, "description": null, - "name": "nameContainsFold", + "name": "transactionHashContainsFold", "type": { "kind": "SCALAR", "name": "String", @@ -1473,8 +3304,8 @@ }, { "defaultValue": null, - "description": "username field predicates", - "name": "username", + "description": "details field predicates", + "name": "details", "type": { "kind": "SCALAR", "name": "String", @@ -1484,7 +3315,7 @@ { "defaultValue": null, "description": null, - "name": "usernameNEQ", + "name": "detailsNEQ", "type": { "kind": "SCALAR", "name": "String", @@ -1494,7 +3325,7 @@ { "defaultValue": null, "description": null, - "name": "usernameIn", + "name": "detailsIn", "type": { "kind": "LIST", "name": null, @@ -1512,7 +3343,7 @@ { "defaultValue": null, "description": null, - "name": "usernameNotIn", + "name": "detailsNotIn", "type": { "kind": "LIST", "name": null, @@ -1530,7 +3361,7 @@ { "defaultValue": null, "description": null, - "name": "usernameGT", + "name": "detailsGT", "type": { "kind": "SCALAR", "name": "String", @@ -1540,7 +3371,7 @@ { "defaultValue": null, "description": null, - "name": "usernameGTE", + "name": "detailsGTE", "type": { "kind": "SCALAR", "name": "String", @@ -1550,7 +3381,7 @@ { "defaultValue": null, "description": null, - "name": "usernameLT", + "name": "detailsLT", "type": { "kind": "SCALAR", "name": "String", @@ -1560,7 +3391,7 @@ { "defaultValue": null, "description": null, - "name": "usernameLTE", + "name": "detailsLTE", "type": { "kind": "SCALAR", "name": "String", @@ -1570,7 +3401,7 @@ { "defaultValue": null, "description": null, - "name": "usernameContains", + "name": "detailsContains", "type": { "kind": "SCALAR", "name": "String", @@ -1580,7 +3411,7 @@ { "defaultValue": null, "description": null, - "name": "usernameHasPrefix", + "name": "detailsHasPrefix", "type": { "kind": "SCALAR", "name": "String", @@ -1590,7 +3421,7 @@ { "defaultValue": null, "description": null, - "name": "usernameHasSuffix", + "name": "detailsHasSuffix", "type": { "kind": "SCALAR", "name": "String", @@ -1600,7 +3431,27 @@ { "defaultValue": null, "description": null, - "name": "usernameEqualFold", + "name": "detailsIsNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "detailsNotNil", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "detailsEqualFold", "type": { "kind": "SCALAR", "name": "String", @@ -1610,7 +3461,7 @@ { "defaultValue": null, "description": null, - "name": "usernameContainsFold", + "name": "detailsContainsFold", "type": { "kind": "SCALAR", "name": "String", @@ -1811,8 +3662,8 @@ }, { "defaultValue": null, - "description": "teams edge predicates", - "name": "hasTeams", + "description": "account edge predicates", + "name": "hasAccount", "type": { "kind": "SCALAR", "name": "Boolean", @@ -1822,7 +3673,7 @@ { "defaultValue": null, "description": null, - "name": "hasTeamsWith", + "name": "hasAccountWith", "type": { "kind": "LIST", "name": null, @@ -1831,7 +3682,7 @@ "name": null, "ofType": { "kind": "INPUT_OBJECT", - "name": "TeamWhereInput", + "name": "AccountWhereInput", "ofType": null } } @@ -1839,8 +3690,8 @@ }, { "defaultValue": null, - "description": "controllers edge predicates", - "name": "hasControllers", + "description": "controller edge predicates", + "name": "hasController", "type": { "kind": "SCALAR", "name": "Boolean", @@ -1850,7 +3701,7 @@ { "defaultValue": null, "description": null, - "name": "hasControllersWith", + "name": "hasControllerWith", "type": { "kind": "LIST", "name": null, @@ -1864,39 +3715,11 @@ } } } - }, - { - "defaultValue": null, - "description": "membership edge predicates", - "name": "hasMembership", - "type": { - "kind": "SCALAR", - "name": "Boolean", - "ofType": null - } - }, - { - "defaultValue": null, - "description": null, - "name": "hasMembershipWith", - "type": { - "kind": "LIST", - "name": null, - "ofType": { - "kind": "NON_NULL", - "name": null, - "ofType": { - "kind": "INPUT_OBJECT", - "name": "AccountTeamWhereInput", - "ofType": null - } - } - } } ], "interfaces": [], "kind": "INPUT_OBJECT", - "name": "AccountWhereInput", + "name": "ActivityWhereInput", "possibleTypes": [] }, { @@ -2088,6 +3911,83 @@ } } } + }, + { + "args": [ + { + "defaultValue": null, + "description": "Returns the elements in the list that come after the specified cursor.", + "name": "after", + "type": { + "kind": "SCALAR", + "name": "Cursor", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Returns the first _n_ elements from the list.", + "name": "first", + "type": { + "kind": "SCALAR", + "name": "Int", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Returns the elements in the list that come before the specified cursor.", + "name": "before", + "type": { + "kind": "SCALAR", + "name": "Cursor", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Returns the last _n_ elements from the list.", + "name": "last", + "type": { + "kind": "SCALAR", + "name": "Int", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Ordering options for Activities returned from the connection.", + "name": "orderBy", + "type": { + "kind": "INPUT_OBJECT", + "name": "ActivityOrder", + "ofType": null + } + }, + { + "defaultValue": null, + "description": "Filtering options for Activities returned from the connection.", + "name": "where", + "type": { + "kind": "INPUT_OBJECT", + "name": "ActivityWhereInput", + "ofType": null + } + } + ], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "activities", + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "OBJECT", + "name": "ActivityConnection", + "ofType": null + } + } } ], "inputFields": [], @@ -3088,6 +4988,34 @@ } } } + }, + { + "defaultValue": null, + "description": "activities edge predicates", + "name": "hasActivities", + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "hasActivitiesWith", + "type": { + "kind": "LIST", + "name": null, + "ofType": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "INPUT_OBJECT", + "name": "ActivityWhereInput", + "ofType": null + } + } + } } ], "interfaces": [], @@ -3515,13 +5443,9 @@ "description": null, "name": "world", "type": { - "kind": "NON_NULL", - "name": null, - "ofType": { - "kind": "SCALAR", - "name": "String", - "ofType": null - } + "kind": "SCALAR", + "name": "String", + "ofType": null } }, { @@ -3583,6 +5507,16 @@ "name": "Boolean", "ofType": null } + }, + { + "defaultValue": null, + "description": null, + "name": "configFile", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } } ], "interfaces": [], @@ -8941,13 +10875,19 @@ "description": null, "name": "id", "type": { - "kind": "NON_NULL", - "name": null, - "ofType": { - "kind": "SCALAR", - "name": "String", - "ofType": null - } + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "username", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null } } ], @@ -9017,13 +10957,19 @@ "description": null, "name": "id", "type": { - "kind": "NON_NULL", - "name": null, - "ofType": { - "kind": "SCALAR", - "name": "String", - "ofType": null - } + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + { + "defaultValue": null, + "description": null, + "name": "username", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null } } ], @@ -9585,6 +11531,11 @@ "name": "AccountTeam", "ofType": null }, + { + "kind": "OBJECT", + "name": "Activity", + "ofType": null + }, { "kind": "OBJECT", "name": "Controller", @@ -14525,6 +16476,18 @@ "name": "Boolean", "ofType": null } + }, + { + "args": [], + "deprecationReason": null, + "description": null, + "isDeprecated": false, + "name": "configFile", + "type": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } } ], "inputFields": [], diff --git a/slot/src/graphql/deployments/create.graphql b/slot/src/graphql/deployments/create.graphql index 415f24b..cecfe95 100644 --- a/slot/src/graphql/deployments/create.graphql +++ b/slot/src/graphql/deployments/create.graphql @@ -28,6 +28,7 @@ mutation CreateDeployment( indexPending indexRawEvents indexTransactions + configFile } ... on SayaConfig {