Skip to content

Commit

Permalink
fix(base URL): change base url from test to production
Browse files Browse the repository at this point in the history
  • Loading branch information
safeerraees committed Jan 5, 2022
1 parent 62145eb commit f8c16fe
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ This API gives you programmatic access to APIMatic's Code Generation, Docs Gener
Run the following command from your project directory to install the package from npm:

```ts
npm install @apimatic/sdk@0.0.1-alpha.2
npm install @apimatic/sdk@0.0.1-alpha.10

```

## Initialize the API Client
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@apimatic/sdk",
"description": "This API gives you programmatic access to APIMatic's Code Generation, Transformers Engine and Docs Generation.",
"author": "Team APIMatic",
"version": "0.0.1-alpha.2",
"version": "0.0.1-alpha.10",
"license": "MIT",
"sideEffects": false,
"main": "dist/index.js",
Expand Down
8 changes: 2 additions & 6 deletions src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,7 @@ export class Client implements ClientInterface {
timeout: this._config.timeout,
clientConfigOverrides: this._config.unstable_httpClientOptions,
}),
[
withErrorHandlers,
withUserAgent,
withAuthenticationByDefault,
],
[withErrorHandlers, withUserAgent, withAuthenticationByDefault],
new XmlSerialization()
);
}
Expand All @@ -72,7 +68,7 @@ function createHttpClientAdapter(client: HttpClient): HttpClientInterface {
function getBaseUri(server: Server = 'default', config: Configuration): string {
if (config.environment === Environment.Production) {
if (server === 'default') {
return 'https://apimaticio-test.azurewebsites.net/api';
return 'https://www.apimatic.io/api';
}
}
throw new Error('Could not get Base URL. Invalid environment or server.');
Expand Down

0 comments on commit f8c16fe

Please sign in to comment.