Hi,
I have been struggling with fetching the data from monday.com using GraphQL, C#, PostRequest.
I have been getting 'No query string was present ’ but the account number is fetched correctly.
I’m new to Monday.com and currently working on new Feature to integrate Monday with our product.
the returned json object.
{“errors”:[{“message”:“No query string was present”}],“account_id”:XXX}
I hope someone can help with this Issue or guide me.
I’m using https NOT http
Thanks
public async Task GetBoardItems([FromQuery] long boardId)
{
string query = @“query {
boards(ids: boardID){
items {
id
name
created_at
creator_id
column_values {
id
title
value
text
}
updates{
item_id
text_body
created_at
updated_at
}
}
}
}”;
query = query.Replace("boardID", boardId.ToString());
var json = new JavaScriptSerializer().Serialize(query);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var responseFromServer = await client.PostAsync(url, content);
var contents = await responseFromServer.Content.ReadAsStringAsync();
var boardItems = JsonConvert.DeserializeObject<Root>(contents);
return boardItems;
}