query
Lookup an App by ID or return the currently authenticated App.
- Get an app by its ID
- Get the currently authenticated app
- Get the feedback field
Examples
1const { admin } = await authenticate.admin(request);23const response = await admin.graphql(4 `#graphql5 query {6 app(id: "gid://shopify/App/193172482") {7 title8 }9 }`,10);1112const data = await response.json();13
query {
app(id: "gid://shopify/App/193172482") {
title
}
}
curl -X POST \
https://your-development-store.myshopify.com/admin/api/unstable/graphql.json \
-H 'Content-Type: application/json' \
-H 'X-Shopify-Access-Token: {access_token}' \
-d '{
"query": "query { app(id: \"gid://shopify/App/193172482\") { title } }"
}'
const { admin } = await authenticate.admin(request);
const response = await admin.graphql(
`#graphql
query {
app(id: "gid://shopify/App/193172482") {
title
}
}`,
);
const data = await response.json();
const client = new shopify.clients.Graphql({session});
const data = await client.query({
data: `query {
app(id: "gid://shopify/App/193172482") {
title
}
}`,
});
session = ShopifyAPI::Auth::Session.new(
shop: "your-development-store.myshopify.com",
access_token: access_token
)
client = ShopifyAPI::Clients::Graphql::Admin.new(
session: session
)
query = <<~QUERY
query {
app(id: "gid://shopify/App/193172482") {
title
}
}
QUERY
response = client.query(query: query)
Response
JSON1{2 "app": {3 "title": "Invoicing Application"4 }5}