https://prefect.io logo
p

Peyton Runyan

01/28/2021, 2:14 PM
Hi all! I'm fairly new to devops and data engineering, quite new to prefect, and brand new to graphql. I'm trying run prefect locally and submit a secret via the graphql ui. I can
prefect server start --use-volume
then navigate to
<http://0.0.0.0:4200/>
to access the graphql gui, and then input
Copy code
mutation {
  set_secret(input: { name: "app_pw", value: "values_of_password" }) {
    success
  }
}
per this documentation https://docs.prefect.io/orchestration/concepts/secrets.html#graphql and I get back an error
Copy code
{
  "error": {
    "errors": [
      {
        "message": "Cannot query field \"set_secret\" on type \"Mutation\".",
        "locations": [
          {
            "line": 2,
            "column": 3
          }
        ],
        "extensions": {
          "code": "GRAPHQL_VALIDATION_FAILED"
        }
      }
    ]
  }
}
I get a similar error trying
Copy code
query {
  secret(order_by: { name: asc }) {
    name
  }
}
j

Jeremiah

01/28/2021, 2:26 PM
Hi @Peyton Runyan, that API is part of Prefect Cloud; Prefect Server does not include a secret manager that you can access via API. Instead, secrets can be loaded from local context.
🙏 1
1
2 Views