Add REST to platforms and SDKs
This commit is contained in:
parent
9fbf8d6aee
commit
c5bda4d2ff
2 changed files with 47 additions and 5 deletions
|
@ -146,7 +146,7 @@ return [
|
|||
'dev' => false,
|
||||
'hidden' => true,
|
||||
'family' => APP_PLATFORM_CLIENT,
|
||||
'prism' => 'graphql',
|
||||
'prism' => 'http',
|
||||
'source' => \realpath(__DIR__ . '/../sdks/client-graphql'),
|
||||
'gitUrl' => '',
|
||||
'gitRepoName' => '',
|
||||
|
@ -154,6 +154,25 @@ return [
|
|||
'gitBranch' => '',
|
||||
'isSDK' => false,
|
||||
],
|
||||
[
|
||||
'key' => 'rest',
|
||||
'name' => 'REST',
|
||||
'version' => '',
|
||||
'url' => '',
|
||||
'package' => '',
|
||||
'enabled' => true,
|
||||
'beta' => false,
|
||||
'dev' => false,
|
||||
'hidden' => true,
|
||||
'family' => APP_PLATFORM_CLIENT,
|
||||
'prism' => 'http',
|
||||
'source' => \realpath(__DIR__ . '/../sdks/client-rest'),
|
||||
'gitUrl' => '',
|
||||
'gitRepoName' => '',
|
||||
'gitUserName' => '',
|
||||
'gitBranch' => '',
|
||||
'isSDK' => false,
|
||||
],
|
||||
],
|
||||
],
|
||||
|
||||
|
@ -176,8 +195,8 @@ return [
|
|||
'family' => APP_PLATFORM_CONSOLE,
|
||||
'prism' => 'console',
|
||||
'source' => \realpath(__DIR__ . '/../sdks/console-web'),
|
||||
'gitUrl' => null,
|
||||
'gitBranch' => null,
|
||||
'gitUrl' => '',
|
||||
'gitBranch' => '',
|
||||
'gitRepoName' => 'sdk-for-console',
|
||||
'gitUserName' => 'appwrite',
|
||||
],
|
||||
|
@ -422,7 +441,7 @@ return [
|
|||
'dev' => false,
|
||||
'hidden' => true,
|
||||
'family' => APP_PLATFORM_SERVER,
|
||||
'prism' => 'graphql',
|
||||
'prism' => 'http',
|
||||
'source' => \realpath(__DIR__ . '/../sdks/server-graphql'),
|
||||
'gitUrl' => '',
|
||||
'gitRepoName' => '',
|
||||
|
@ -430,6 +449,25 @@ return [
|
|||
'gitBranch' => '',
|
||||
'isSDK' => false,
|
||||
],
|
||||
[
|
||||
'key' => 'rest',
|
||||
'name' => 'REST',
|
||||
'version' => '',
|
||||
'url' => '',
|
||||
'package' => '',
|
||||
'enabled' => true,
|
||||
'beta' => false,
|
||||
'dev' => false,
|
||||
'hidden' => true,
|
||||
'family' => APP_PLATFORM_SERVER,
|
||||
'prism' => 'http',
|
||||
'source' => \realpath(__DIR__ . '/../sdks/server-rest'),
|
||||
'gitUrl' => '',
|
||||
'gitRepoName' => '',
|
||||
'gitUserName' => '',
|
||||
'gitBranch' => '',
|
||||
'isSDK' => false,
|
||||
],
|
||||
],
|
||||
],
|
||||
];
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
<?php
|
||||
|
||||
use Appwrite\SDK\Language\GraphQL;
|
||||
use Appwrite\SDK\Language\HTTP;
|
||||
use Appwrite\SDK\Language\REST;
|
||||
use Utopia\Config\Config;
|
||||
use Utopia\CLI\Console;
|
||||
use Appwrite\Spec\Swagger2;
|
||||
|
@ -165,9 +167,11 @@ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
|||
case 'graphql':
|
||||
$config = new GraphQL();
|
||||
break;
|
||||
case 'rest':
|
||||
$config = new REST();
|
||||
break;
|
||||
default:
|
||||
throw new Exception('Language "' . $language['key'] . '" not supported');
|
||||
break;
|
||||
}
|
||||
|
||||
Console::info("Generating {$language['name']} SDK...");
|
||||
|
|
Loading…
Reference in a new issue