@api-client/core 0.19.26 → 0.19.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@api-client/core",
3
3
  "description": "The API Client's core client library. Works in NodeJS and in a ES enabled browser.",
4
- "version": "0.19.26",
4
+ "version": "0.19.27",
5
5
  "license": "UNLICENSED",
6
6
  "exports": {
7
7
  "./browser.js": {
@@ -50,14 +50,16 @@ export class OrganizationsSdk extends SdkBase {
50
50
  /**
51
51
  * Creates a new organization.
52
52
  * @param orgName The name of the organization to create.
53
+ * @param orgSlug The slug of the organization to create.
53
54
  * @param request The request options.
54
55
  * @returns A promise that resolves to the created organization.
55
56
  */
56
- async create(orgName: string, request: SdkOptions = {}): Promise<OrganizationSchema> {
57
+ async create(orgName: string, orgSlug: string, request: SdkOptions = {}): Promise<OrganizationSchema> {
57
58
  const { token } = request
58
59
  const url = this.sdk.getUrl(RouteBuilder.organizations())
59
60
  const body = {
60
61
  name: orgName,
62
+ slug: orgSlug,
61
63
  }
62
64
  const result = await this.sdk.http.post(url.toString(), {
63
65
  body: JSON.stringify(body),
@@ -83,7 +83,7 @@ export interface MockListResult extends MockResult {
83
83
  * await mocker.organizations.list();
84
84
  *
85
85
  * // Custom response with specific data
86
- * await mocker.organizations.create({
86
+ * await mocker.organizations.create("name", "slug", {
87
87
  * response: {
88
88
  * status: 201,
89
89
  * headers: { 'Content-Type': 'application/json', 'X-Custom-Header': 'value' },