From f4ec1a88b655e64372d30166b69021e2a17b2a90 Mon Sep 17 00:00:00 2001 From: John Estabrook Date: Mon, 22 Nov 2021 09:28:31 -0600 Subject: graphql: T3993: update README.graphql --- src/services/api/graphql/README.graphql | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/services/api/graphql/README.graphql b/src/services/api/graphql/README.graphql index c91b70782..0ddcb578a 100644 --- a/src/services/api/graphql/README.graphql +++ b/src/services/api/graphql/README.graphql @@ -42,6 +42,8 @@ mutation { } } +To save the configuration, use the following mutation: + mutation { saveConfigFile(data: {fileName: "/config/config.boot"}) { success @@ -52,8 +54,14 @@ mutation { } } -N.B. fileName can be empty (fileName: "") or data can be empty (data: {}) to save to -/config/config.boot; to save to an alternative path, specify fileName. +N.B. fileName can be empty (fileName: "") or data can be empty (data: {}) to +save to /config/config.boot; to save to an alternative path, specify +fileName. + +Similarly, using the same 'endpoint' (meaning the form of the request and +resolver; the actual enpoint for all GraphQL requests is +https://hostname/graphql), one can load an arbitrary config file from a +path. mutation { loadConfigFile(data: {fileName: "/home/vyos/config.boot"}) { -- cgit v1.2.3