HI all, i have an issue Fetching data from board using PHP and new API Version 2024-01. it was working fine from previous version.
Thus far, I have made the following changes:
added API=version at the end of header
$headers = [‘Content-Type: application/json’, ‘Authorization: ’ . $token.’, API-version : 2024-01’];
I changed the query to include items_page
The query works perfect as it works fine and returns results on monday.com
query {
boards (ids: 12344444444)
{ items_page {
items { name column_values
{ id type text }
} }}
}
I am trying to parse the content, but get stuck here as I get null results
foreach($responseContent[‘data’][‘boards’][‘items_page’][‘items’][0] as $mydata){
or
foreach($responseContent[‘data’][‘boards’][‘items_page’][‘items’] as $mydata){
Paste the query into the graphql developer console first to test it works (selecting the correct api version).
If it works, try:
print_r($responseContent);
To see what you got back from the API.
It would be really cool if all results returned also had the api version displayed, so you know whether the version is that one you think you’ve specified @Matias.Monday