From 07b59a9623a8f4698d72031f70c42f7e7acae82c Mon Sep 17 00:00:00 2001 From: Jeff Shillitto Date: Sat, 19 Oct 2019 22:58:02 +1100 Subject: [PATCH 1/3] Add Shotstack to in the wild list --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 8bd77a39..596e7e5e 100644 --- a/README.md +++ b/README.md @@ -271,6 +271,7 @@ Please feel free to add a link to your API documentation here. * [Split Payments API](http://docs.split.cash/) * [LeApp daemon API](https://leapp-to.github.io/shins/index.html) * [Shutterstock API](https://api-reference.shutterstock.com/) +* [Shotstack Video Editing API](https://shotstack.io/docs/api/index.html) ### Widdershins and Shins From a1d28a7c12f075349444a7c30b476265c1559176 Mon Sep 17 00:00:00 2001 From: Jeff Shillitto Date: Thu, 31 Dec 2020 22:18:07 +1100 Subject: [PATCH 2/3] Fix missing code and use modern PHP7 array syntax --- templates/openapi3/code_php.dot | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/templates/openapi3/code_php.dot b/templates/openapi3/code_php.dot index 5802466b..613a725c 100644 --- a/templates/openapi3/code_php.dot +++ b/templates/openapi3/code_php.dot @@ -1,23 +1,20 @@ - '{{=p.exampleValues.object}}', -{{?index < data.allHeaders.length-1}} {{?}}{{~}});{{?}} +{{?index < data.allHeaders.length-1}} {{?}}{{~}}];{{?}} $client = new \GuzzleHttp\Client(); // Define array of request body. -$request_body = array(); +$request_body = []]; try { - $response = $client->request('{{=data.methodUpper}}','{{=data.url}}', array( + $response = $client->request('{{=data.methodUpper}}','{{=data.url}}', [ 'headers' => $headers, 'json' => $request_body, - ) - ); + ]); print_r($response->getBody()->getContents()); } catch (\GuzzleHttp\Exception\BadResponseException $e) { From c2019adb9d18e97892afd427a0cc1395d3375734 Mon Sep 17 00:00:00 2001 From: Jeff Shillitto Date: Thu, 31 Dec 2020 22:29:31 +1100 Subject: [PATCH 3/3] Remove extra array bracket --- templates/openapi3/code_php.dot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/openapi3/code_php.dot b/templates/openapi3/code_php.dot index 613a725c..327d28e7 100644 --- a/templates/openapi3/code_php.dot +++ b/templates/openapi3/code_php.dot @@ -8,7 +8,7 @@ $headers = [ $client = new \GuzzleHttp\Client(); // Define array of request body. -$request_body = []]; +$request_body = []; try { $response = $client->request('{{=data.methodUpper}}','{{=data.url}}', [