Tmdb Client Error: {"success":false,"status_code":11,"status_message":"Internal error: Something went wrong, contact TMDb.","combined_credits":{"cast":[{"adult":false,"backdrop_path":null,"genre_ids":[10402,99],"id":378058,"original_language":"en","original_title":"Komeda: A Soundtrack for a Life","overview":"Krzysztof Komeda was a jazz pianist and film composer. With compositions like the lullaby for Rosemary's Baby (1968) by Roman Polanski, Komeda succeeded in writing his own chapter in the history of soundtracks. This documentary follows the life story of the composer by the means of his melodic sounds. It is a reflection on his soundtracks, which changed the common film scores forever. It is a contemporary document about the attitude to life in a time of social, political and cultural change after war, about work and exodus of Polish artists in the 50s and 60s. A story about how film music is created and how it affects people. Directors who worked with Komeda and who are also friends talk about him: Roman Polanski, Jerzy Skolimowski, Henning Carlsen and Andrzej Wajda. His wife, Zofia Komeda, and his sister, Irena Orlowska, recollect him.","popularity":1.115,"poster_path":"/y3fISHPV9tAQ85mv9QJqQAMb9gi.jpg","release_date":"2011-07-02","title":"Komeda: A Soundtrack for a Life","video":false,"vote_average":6.5,"vote_count":2,"character":"Self","credit_id":"569c34f69251415e6d00100d","order":3,"media_type":"movie"}],"crew":[{"adult":false,"backdrop_path":null,"genre_ids":[28,18],"id":55028,"original_language":"en","original_title":"Managua","overview":"When a fellow Vietnam veteran is alleged to have thrown his lot in with the cocaine cartels, special commando Paul Gleason is dispatched to Nicaragua to sort out the mess.","popularity":3.504,"poster_path":"/ePxhjXtwEHx4Ps72zbwB4fzViLF.jpg","release_date":"1996-04-09","title":"Managua","video":false,"vote_average":4.3,"vote_count":7,"credit_id":"52fe48b8c3a36847f8175d9f","department":"Writing","job":"Writer","media_type":"movie"},{"adult":false,"backdrop_path":"/mmV2rgiPuaIbOATbcobn0DBiNxy.jpg","genre_ids":[27],"id":57950,"original_language":"en","original_title":"Campfire Stories","overview":"Two teens on their way to a backwoods party come across a beautiful young woman having car trouble. Their search for help only gets them lost, deep in the woods, where they meet Forest Ranger Bill with a penchant for scary stories. The campfire flickers long into the night as the ranger uses words to weave his tapestry of terror, filling their young minds with a host of horrific images that will be burned into your consciousness long after the fire's last embers have gone out. Insane doctors, Indian ghosts, bad drugs, a deranged handyman with shiny new shears - all that and more awaits anyone brave enough to stay until sunrise... if you live that long!\r - Written by Schleppy","popularity":1.268,"poster_path":"/wTQQoXb2KxgxHJGM4c0vQDvsvQl.jpg","release_date":"2001-10-01","title":"Campfire Stories","video":false,"vote_average":2.3,"vote_count":7,"credit_id":"52fe494dc3a36847f81935e7","department":"Directing","job":"Director","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[],"id":250625,"original_language":"en","original_title":"Looking for Palladin","overview":"Brash young Hollywood talent agent Josh Ross (David Moscow) is dispatched to Guatemala, where he's assigned to locate missing star Jack Palladin (Ben Gazzara), a man Josh has never met but can't stand due to Palladin's long-ago relationship with his late mother. Despite receiving no help from the amused locals, Josh eventually finds his target hiding out as a cook at a restaurant but discovers that persuading the reluctant actor to return to Hollywood will be an uphill climb. Talia Shire costars in this independent comedy.","popularity":1.253,"poster_path":"/gTD0QF8S3cfuhTobZWjyNdAD21G.jpg","release_date":"2008-03-05","title":"Looking for Palladin","video":false,"vote_average":3.7,"vote_count":3,"credit_id":"52fe4df89251416c91122291","department":"Writing","job":"Writer","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[],"id":250625,"original_language":"en","original_title":"Looking for Palladin","overview":"Brash young Hollywood talent agent Josh Ross (David Moscow) is dispatched to Guatemala, where he's assigned to locate missing star Jack Palladin (Ben Gazzara), a man Josh has never met but can't stand due to Palladin's long-ago relationship with his late mother. Despite receiving no help from the amused locals, Josh eventually finds his target hiding out as a cook at a restaurant but discovers that persuading the reluctant actor to return to Hollywood will be an uphill climb. Talia Shire costars in this independent comedy.","popularity":1.253,"poster_path":"/gTD0QF8S3cfuhTobZWjyNdAD21G.jpg","release_date":"2008-03-05","title":"Looking for Palladin","video":false,"vote_average":3.7,"vote_count":3,"credit_id":"52fe4df89251416c9112228b","department":"Directing","job":"Director","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[99],"id":998045,"original_language":"en","original_title":"The Politics of Cancer (A Study in Chaos)","overview":"The powerful become powerless as U. S. Senators, scientists, doctors, pharmaceuticals, CEO's, wives and children confront a chaotic epidemic of cancer. Politics, hopes, and realities.","popularity":0.452,"poster_path":null,"release_date":"1994-10-07","title":"The Politics of Cancer (A Study in Chaos)","video":false,"vote_average":0.0,"vote_count":0,"credit_id":"62ca04a9595a56094ee31c27","department":"Writing","job":"Writer","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[99],"id":998045,"original_language":"en","original_title":"The Politics of Cancer (A Study in Chaos)","overview":"The powerful become powerless as U. S. Senators, scientists, doctors, pharmaceuticals, CEO's, wives and children confront a chaotic epidemic of cancer. Politics, hopes, and realities.","popularity":0.452,"poster_path":null,"release_date":"1994-10-07","title":"The Politics of Cancer (A Study in Chaos)","video":false,"vote_average":0.0,"vote_count":0,"credit_id":"62ca04af39a1a6051642a98d","department":"Directing","job":"Director","media_type":"movie"},{"adult":false,"backdrop_path":"/eC061TTyouKa6Hprd4PS801pHpR.jpg","genre_ids":[12,10752,10749,18],"id":31273,"original_language":"pl","original_title":"Ogniem i mieczem","overview":"In the mid-17th century, Poland was the largest, most democratic, and most tolerant country in Europe. However, a tragic civil war brought about the gradual decline of the once glorious republic... An epic story about the Ukrainian uprising against the Polish-Lithuanian Commonwealth magnates in the 17th Century.","popularity":9.335,"poster_path":"/cCCeqG9sjts6H6LKKgDnqcQuVtq.jpg","release_date":"1999-02-08","title":"With Fire and Sword","video":false,"vote_average":7.0,"vote_count":93,"credit_id":"56d8d8cc9251412e28003141","department":"Writing","job":"Screenplay","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[18],"id":469091,"original_language":"en","original_title":"Tides of War","overview":"Nazis aim a secret weapon at the USA during WW2. The only people who can stop it must race against time and overwhelming odds.","popularity":0.966,"poster_path":"/5qjxnIaverrJOfoCWr0PQWReQA5.jpg","release_date":"1990-01-01","title":"Tides of War","video":false,"vote_average":6.0,"vote_count":1,"credit_id":"59813118925141519b00807a","department":"Writing","job":"Writer","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[18],"id":469091,"original_language":"en","original_title":"Tides of War","overview":"Nazis aim a secret weapon at the USA during WW2. The only people who can stop it must race against time and overwhelming odds.","popularity":0.966,"poster_path":"/5qjxnIaverrJOfoCWr0PQWReQA5.jpg","release_date":"1990-01-01","title":"Tides of War","video":false,"vote_average":6.0,"vote_count":1,"credit_id":"5981315a92514151e700826a","department":"Production","job":"Co-Producer","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[18,28],"id":72175,"original_language":"en","original_title":"Portrait of a Hitman","overview":"A professional hitman is hired to kill a brain surgeon. However, it turns out that not only are he and the surgeon old friends, but they are both in love with the same woman.","popularity":1.367,"poster_path":"/9xXWyjFbG9WOMTZ48ZhrtUzoTHB.jpg","release_date":"1979-05-11","title":"Portrait of a Hitman","video":false,"vote_average":4.2,"vote_count":6,"credit_id":"66361d90470ead0128126487","department":"Production","job":"Producer","media_type":"movie"},{"adult":false,"backdrop_path":null,"genre_ids":[99,18],"id":1276874,"original_language":"pl","original_title":"Życie i śmierci Maxa Lindera","overview":"Searching for documentation about Max Linder, we found in an abandoned house a trunk sealed for 100 years, with a film from 1926 by an unknown filmmaker. The film depicts Max Linder, the first international screen star who was once revered in France, throughout Europe and in Hollywood. This pioneer of early silent film comedy was a mentor to Charlie Chaplin. Max miraculously avoided death five times. And finally, at the height of his artistic powers, he and his adored wife committed a double suicide. How was this possible?","popularity":0.768,"poster_path":"/nJpSem55sAOuxNBk7NCgx0S0vcm.jpg","release_date":"2024-05-13","title":"Life and Deaths of Max Linder","video":false,"vote_average":0.0,"vote_count":0,"credit_id":"663f60ede63b0f9f8dd60045","department":"Production","job":"Executive Producer","media_type":"movie"},{"adult":false,"backdrop_path":"/uAr0WNk16NMBT5ezoaIFVqFVCgQ.jpg","genre_ids":[18,10752],"id":56179,"original_language":"en","original_title":"Triumph of the Spirit","overview":"During World War II, Salamo Arouch, a passionate boxer, is arrested and sent to a concentration camp. Soon, he is forced to box against his fellow prisoners for the sake of entertainment.","popularity":11.089,"poster_path":"/dxaSARmpCiFOCaxwGvjYAXMYPE4.jpg","release_date":"1989-12-08","title":"Triumph of the Spirit","video":false,"vote_average":6.6,"vote_count":49,"credit_id":"5c98e4160e0a264cc3c32edf","department":"Writing","job":"Writer","media_type":"movie"},{"adult":false,"backdrop_path":"/hwYCpngQyRh5TmBaT8QtVFwAtPJ.jpg","genre_ids":[18],"id":299572,"original_language":"en","original_title":"Eminent Domain","overview":"A high-ranking Polish politburo member is banished from the party, and must find out why. Set in 1979 Poland before the Solidarity events.","popularity":4.811,"poster_path":"/8dPIZYcwdK6tmVF0680L224SErt.jpg","release_date":"1991-04-12","title":"Eminent Domain","video":false,"vote_average":5.8,"vote_count":17,"credit_id":"6035cd846cf3d5003efdba43","department":"Writing","job":"Screenplay","media_type":"movie"},{"adult":false,"backdrop_path":"/hwYCpngQyRh5TmBaT8QtVFwAtPJ.jpg","genre_ids":[18],"id":299572,"original_language":"en","original_title":"Eminent Domain","overview":"A high-ranking Polish politburo member is banished from the party, and must find out why. Set in 1979 Poland before the Solidarity events.","popularity":4.811,"poster_path":"/8dPIZYcwdK6tmVF0680L224SErt.jpg","release_date":"1991-04-12","title":"Eminent Domain","video":false,"vote_average":5.8,"vote_count":17,"credit_id":"6035cd9c5b370d00403b8d51","department":"Writing","job":"Story","media_type":"movie"}]}}
96 'Content-Type' => 'application/json;charset=utf-8',
97 'Authorization' => sprintf('Bearer %s', Configurator::$instance->get('tmdb'))
98 ];
99
100 // Append language preference to headers to avoid adult content
101 $headers['Accept-Language'] = 'en-US'; // Example: Set language preference to English
102
103 // Make the GET request with headers
104 $resp = EasyCurl::setHeaders($headers)->get(...$args);
105
106 // Check if response status is not 200 OK
107 if ($resp->getStatus() != 200) {
108 throw new TmdbClientException('Tmdb Client Error: ' . $resp->getBody(), $resp->getStatus());
109 }
110
111 // Check for adult content in response (assuming TMDB API supports such filtering)
112 $jsonResponse = json_decode($resp->getBody(), true);
113
114
115 return $resp;
116 }
117
118
119 public function getGenre(): array
120 {
121 return $this->request('genre/' . $this->getType() . '/list')['genres'] ?? [];