Questions tagged [graphql]
GraphQL is an open-source data query and manipulation language for APIs, and a runtime for fulfilling queries with existing data. GraphQL was developed internally by Facebook. All questions related to GraphQL in Sitecore environment, should consider this tag.
39
questions
1
vote
0answers
16 views
Make sure the GraphQL service is installed and available (Sitecore 10 CLI) [duplicate]
When I try to use one of these commands
dotnet sitecore ser push
dotnet sitecore ser pull
dotnet sitecore ser publish
I got this error
Make sure the GraphQL service is installed and available
I ...
0
votes
0answers
25 views
Is there a change in contract between JSS version 11 and 14?
I am currently using sitecore 9.0.2 and have installed JSS to query the data using graphQL queries. I use below features of JSS:
Querying data using http://sitecore.local/sitecore/api/graph/items/...
0
votes
1answer
27 views
Does installing JSS package on sitecore modify database schema
I am planning to install JSS package on my sitecore instance to use GraphQL APIs. I want to know wether installing JSS package change/alter my database schema or solr indexes. In case I want to ...
2
votes
2answers
70 views
How to query Specialized TreeList using GraphQL
I have an item in sitecore which has a field with Specialized Treelist selection. I want to query this field using GraphQL query.
Query:
{
item(path: "{98414240-69F7-4768-9B22-FE8EF17BE984}&...
0
votes
1answer
68 views
Image not working when fetching it with GraphQL in connected mode
This is on sitecore 10 / jss 14.0.1
I'm using JSS in connected mode (jss start:connected) since I will be fetching data with GraphQL. In my graphQL I fetch an image using this code:
item(path: $item)...
2
votes
2answers
170 views
Error message “Make sure the GraphQL service is installed and available”
Installed fresh Sitecore 10 and trying to use Sitecore CLI combined with native Sitecore Content Serialization.
When executing next command
dotnet sitecore ser pull
I get an error message
Make sure ...
2
votes
1answer
61 views
0
votes
1answer
86 views
How to pass a variable to search context?
I have created a SearchContext, defined query, provider etc. I have a variable to pass so can get result depending on what is being passed.
Now, how do I pass this $query variable (which will be a ...
1
vote
1answer
48 views
SitecoreJSS DateField is not able to format date coming from GraphQl query
I'm getting a Date from GraphQl query. When I get the result, it is coming as 20200415T123050Z.
If I try to format using
<DateField field={item.publishDate} render={(date) => date....
0
votes
1answer
68 views
GraphQL query to search for pages based on template
The following GraphQL query returns items based on the Page template:
search(keyword: "Dream",
first: 10,
language: "en",
fieldsEqual: [{name:"_templatename", value:"Page" }]
) {
...
2
votes
2answers
135 views
Custom response for field and value from GraphQL query
While executing below GraphQL query using Sitecore Experience Graph Browser
{
item(path:"/sitecore/content/home")
{
name
fields {
name
value
}
}
}
the response is as ...
3
votes
1answer
497 views
Cannot query field \“search\” on type \“Query\”
My question is based on already asked question and can be found here Sitecore Filtering by Field Value on Query of GraphQL
This question is marked as answered by @jan-bluemink but I am facing the ...
3
votes
1answer
353 views
Integrated GraphQL is not working correctly with JSS with SXA
I've been struggling for a few days to get JSS Integrated GraphQL running on an existing SXA project. To rule out any issues being introduced by this project, I decided to go right back to square one, ...
3
votes
2answers
231 views
Integrated GraphQL is not executed in Experience Editor
We use Sitecore 9.2, SXA 1.9 + JSS 12.0. As for the JSS, we are using Sitecore First approach. Some JSON renderings have integrated GraphQL queries.
The Jss site was created trough JSS Tenant/JSS ...
0
votes
1answer
157 views
Manage security access for items with GraphQL
We noticed that there is no limitation on what data can be queried, all the data in GraphQL can be retrieved within the Sitecore instance.
Any GraphQL request with the correct API Key can retrieve ...
1
vote
1answer
142 views
Get the item from a ReferenceField type in Sitecore JSS based on Langauge version
I am working on a multi-lingual site where the data source has multiple language versions. I want to retrieve the items of multilist based on the language parameter passed.
Sitecore GraphQL query:
{...
0
votes
0answers
104 views
Using Sitecore GraphQl in C# and send data to JSS
I am figuring out the Sitecore GraphQL Query where I need to use it as a query in my C# code (if that possible) where I just get all the items of a specific location in the Sitecore Tree. However, I ...
2
votes
1answer
76 views
Can you resolve a droplink to an item within a GraphQL?
I have a template with a droplink "productarea". When I use a GraphQL to fetch this item, the value of the "productarea" is a GUID. This guid points to an item in the sitecore tree, and I need the ...
1
vote
1answer
83 views
Sitecore graphql gui does not work over https
The sitecore graphql gui uses websockets to communicate with the server. We have a site that is running under https, but it seems that the gui frontend always uses ws instead of switching to it's ...
1
vote
1answer
205 views
GraphQL datasource is empty with Integrated JSS App
I have a query that is working in the GraphiQL UI :
query GetBreadcrumb($datasource: String!) {
datasource(value: $datasource) {
...mySelectedFields
parent {
...mySelectedFields
...
4
votes
1answer
210 views
GraphQL Search facetOn Parameter
I'm trying to use the Sitecore GraphQL search function that takes in the "facetOn" parameter. Unfortunately I'm not having much luck with the results, and I suspect it's because I'm doing something ...
0
votes
1answer
191 views
In JSS how do I support both secure and open GraphQL endpoints?
In my JSS application, how do I support both authenticated (logged in) GraphQL endpoints and in-secure (public/open) GraphQL endpoints?
The example Angular application shows the usage of only one ...
0
votes
1answer
74 views
Access Denied when using Mutation to create Item JSS Graphql
I created a form that when a user submit, values on that form will be created as field values of a new Sitecore Item.
However, I encountered an error response from the GraphQL execution of Access ...
0
votes
1answer
244 views
GraphQL Search Query INVALID_OPERATION
The Query:
{
search(fieldsEqual:[
{name:"_fullpath", value:"/sitecore/content/*" }
]) {
results {
totalCount
}
}
}
The Result:
"data": {
"search": null
},
"...
1
vote
1answer
174 views
GraphQL Filter on PageType
I have been successfully using GraphQL to filter on items assigned to a specific template.
Is it possible to do the same with items of a certain PageType?
0
votes
1answer
96 views
graphql is emtpy when using integrated mode
I have a GraphQL to fill in my menu. When I use jss start:connected it works just fine, but when I deploy (jss deploy app) and get it from the server it's empty.
I have been digging a bit into what'...
1
vote
0answers
211 views
What is the best way to flatten structure
I have a structure where directly below the /home node I wish to have all the stores. Each store should have information like opening hours and address. This data was created as a component. This ...
-1
votes
1answer
184 views
Sitecore came up with GraphQL in 9.2, so internally does they use Sitecore API?
What does GraphQL use internally to query the Sitecore items?
2
votes
2answers
305 views
Access Referenced Items using Integrated GraphQL
I am having following content tree:
In GraphQL (GQL), if I am rendering Product-1 (current context item) and wanted to access all the categories where Product-1 referenced in
the multi-list field of ...
0
votes
1answer
552 views
Sitecore GraphQL Search query not working - Error trying to resolve search [duplicate]
I have the checked my instance and search query is enabled. I am getting the below error when i testing my search query in xGraph Browser
Query
query{
search(keyword:"smart"){
results{
...
6
votes
1answer
277 views
Error in component using integrated GraphQL search query “Cannot read property search of undefined”
Component definition
export default function (manifest) {
manifest.addComponent({
name: 'Navigation',
graphQLQuery: `
query NavigationQuery {
search(
fieldsEqual: [
...
10
votes
1answer
3k views
Cannot query field “search” on type “Query”
I would like to display in a view a list of items provided by a search on GraphQL query.
Context:
Sitecore 9.1
Jss 11.0.0
Jss application template : Angular
Componant file heroes-connected....
5
votes
1answer
385 views
Graphql image size
I am implementing Sitecore jss on Sitecore version 9.1.
I was wondering if there is a way to specify the image size (width/height) when querying using GraphQl.
Below is my current query which is ...
0
votes
1answer
413 views
Search query error “Cannot query field \”search\“ on type \”Query\"
I'm trying to get data using GraphQL query with using search and get it when testing at /sitecore/api/graph/items/master/ui window - search really work, but when I look at the React component data ...
1
vote
1answer
434 views
Fetching Multiple Item Data using GraphQL
I want to fetch multiple item data using single query.
I am able to fetch the data of single item.
My tree structure is like:
Item1:
Title
Description
Item2:
Title
Description
...
0
votes
1answer
1k views
Sitecore Filtering by Field Value on Query of GraphQL
I am currently working on trying out the Sitecore GraphQL Query where I just get all the items of a specific location in the Sitecore Tree. However, I may need to filter the item results based on a ...
3
votes
1answer
497 views
Profiling Sitecore 9.1 JSS Server-Side-rendering node server
JSS site is running in integrated mode on Sitecore 9.1
I have problem with the SSR node process, it's hanging around 18 min on load tests and results in error 500 for site.
For blind solution I ...
1
vote
1answer
574 views
Get the Property of an item from a ReferenceField type in Sitecore JSS (react)
I am currently working on a Sitecore JSS in which I am using GraphQL to retrieve data in Sitecore.
I have field named ArticleTag in my context item which is a (Droptree)
Sitecore GraphQL query:
...
4
votes
1answer
177 views
Sitecore, JSS and GraphQL: licensing question
The question is pretty simple: can I use the GraphQL from JSS package without JSS license?