Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/auto-bump-magicbell-js-1760940479.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'magicbell-js': minor
---

Automatic minor version bump for changes in `magicbell-js`.
15 changes: 13 additions & 2 deletions packages/magicbell-js/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.broadcasts.listBroadcasts({
limit: 5,
limit: 10,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand All @@ -87,6 +87,7 @@ The SDK provides various services to interact with the API.
| [EventsService](docs/project-client/services/EventsService.md) |
| [IntegrationsService](docs/project-client/services/IntegrationsService.md) |
| [UsersService](docs/project-client/services/UsersService.md) |
| [WorkflowsService](docs/project-client/services/WorkflowsService.md) |

</details>

Expand Down Expand Up @@ -129,6 +130,9 @@ The SDK includes several models that represent the data structures used in API r
| [ApnsConfigCollection](docs/project-client/models/ApnsConfigCollection.md) | |
| [ApnsConfig](docs/project-client/models/ApnsConfig.md) | |
| [ApnsConfigPayload](docs/project-client/models/ApnsConfigPayload.md) | |
| [EventSourceConfigCollection](docs/project-client/models/EventSourceConfigCollection.md) | |
| [EventSourceConfig](docs/project-client/models/EventSourceConfig.md) | |
| [EventSourceConfigPayload](docs/project-client/models/EventSourceConfigPayload.md) | |
| [ExpoConfigCollection](docs/project-client/models/ExpoConfigCollection.md) | |
| [ExpoConfig](docs/project-client/models/ExpoConfig.md) | |
| [ExpoConfigPayload](docs/project-client/models/ExpoConfigPayload.md) | |
Expand Down Expand Up @@ -168,6 +172,13 @@ The SDK includes several models that represent the data structures used in API r
| [UserCollection](docs/project-client/models/UserCollection.md) | |
| [User](docs/project-client/models/User.md) | |
| [Links](docs/project-client/models/Links.md) | |
| [WorkflowDefinition](docs/project-client/models/WorkflowDefinition.md) | |
| [ExecuteWorkflowRequest](docs/project-client/models/ExecuteWorkflowRequest.md) | |
| [CreateRunResponse](docs/project-client/models/CreateRunResponse.md) | |
| [GetRunResponse](docs/project-client/models/GetRunResponse.md) | |
| [WorkflowRunCollection](docs/project-client/models/WorkflowRunCollection.md) | |
| [WorkflowRun](docs/project-client/models/WorkflowRun.md) | |
| [Links](docs/project-client/models/Links.md) | |

</details>

Expand Down Expand Up @@ -221,7 +232,7 @@ import { Client } from 'magicbell-js/user-client';
});

const { data } = await client.channels.listInboxTokens({
limit: 3,
limit: 6,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down
21 changes: 19 additions & 2 deletions packages/magicbell-js/docs/project-client/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,18 @@ This SDK is compatible with the following versions: `TypeScript >= 4.8.4`

## Installation

To get started with the SDK, we recommend installing using `npm`:
To get started with the SDK, we recommend installing using `npm` or `yarn`:

```bash
npm install magicbell-js
```

or

```bash
yarn add magicbell-js/project-client
```

## Authentication

### Access Token Authentication
Expand Down Expand Up @@ -60,7 +66,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.broadcasts.listBroadcasts({
limit: 5,
limit: 10,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand All @@ -83,6 +89,7 @@ The SDK provides various services to interact with the API.
| [EventsService](services/EventsService.md) |
| [IntegrationsService](services/IntegrationsService.md) |
| [UsersService](services/UsersService.md) |
| [WorkflowsService](services/WorkflowsService.md) |

</details>

Expand Down Expand Up @@ -125,6 +132,9 @@ The SDK includes several models that represent the data structures used in API r
| [ApnsConfigCollection](models/ApnsConfigCollection.md) | |
| [ApnsConfig](models/ApnsConfig.md) | |
| [ApnsConfigPayload](models/ApnsConfigPayload.md) | |
| [EventSourceConfigCollection](models/EventSourceConfigCollection.md) | |
| [EventSourceConfig](models/EventSourceConfig.md) | |
| [EventSourceConfigPayload](models/EventSourceConfigPayload.md) | |
| [ExpoConfigCollection](models/ExpoConfigCollection.md) | |
| [ExpoConfig](models/ExpoConfig.md) | |
| [ExpoConfigPayload](models/ExpoConfigPayload.md) | |
Expand Down Expand Up @@ -164,5 +174,12 @@ The SDK includes several models that represent the data structures used in API r
| [UserCollection](models/UserCollection.md) | |
| [User](models/User.md) | |
| [Links](models/Links.md) | |
| [WorkflowDefinition](models/WorkflowDefinition.md) | |
| [ExecuteWorkflowRequest](models/ExecuteWorkflowRequest.md) | |
| [CreateRunResponse](models/CreateRunResponse.md) | |
| [GetRunResponse](models/GetRunResponse.md) | |
| [WorkflowRunCollection](models/WorkflowRunCollection.md) | |
| [WorkflowRun](models/WorkflowRun.md) | |
| [Links](models/Links.md) | |

</details>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# CreateRunResponse

**Properties**

| Name | Type | Required | Description |
| :--- | :----- | :------- | :---------- |
| id | string | ✅ | |
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# EventSourceConfig

**Properties**

| Name | Type | Required | Description |
| :----- | :----------------------- | :------- | :---------- |
| config | EventSourceConfigPayload | ✅ | |
| id | string | ✅ | |
| name | string | ✅ | |
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# EventSourceConfigCollection

**Properties**

| Name | Type | Required | Description |
| :---- | :------------------ | :------- | :---------- |
| data | EventSourceConfig[] | ❌ | |
| links | Links | ❌ | |
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# EventSourceConfigPayload

**Properties**

| Name | Type | Required | Description |
| :----- | :----- | :------- | :---------- |
| source | string | ✅ | |
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# ExecuteWorkflowRequest

**Properties**

| Name | Type | Required | Description |
| :---- | :----- | :------- | :---------- |
| key | string | ✅ | |
| input | any | ❌ | |
22 changes: 22 additions & 0 deletions packages/magicbell-js/docs/project-client/models/GetRunResponse.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# GetRunResponse

**Properties**

| Name | Type | Required | Description |
| :---------- | :------------------- | :------- | :---------- |
| createdAt | string | ❌ | |
| id | string | ❌ | |
| status | GetRunResponseStatus | ❌ | |
| workflowKey | string | ❌ | |

# GetRunResponseStatus

**Properties**

| Name | Type | Required | Description |
| :---------- | :----- | :------- | :---------- |
| completedAt | string | ❌ | |
| error | string | ❌ | |
| nextStep | number | ❌ | |
| startedAt | string | ❌ | |
| state | number | ❌ | |
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
| Name | Type | Required | Description |
| :------------------- | :----- | :------- | :--------------------------------------------------------- |
| webhookSigningSecret | string | ✅ | The signing secret to verify incoming requests from Stripe |
| id | string | ❌ | The unique identifier for this configuration |
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# WorkflowDefinition

**Properties**

| Name | Type | Required | Description |
| :------- | :------ | :------- | :---------- |
| key | string | ✅ | |
| steps | Steps[] | ✅ | |
| disabled | boolean | ❌ | |
22 changes: 22 additions & 0 deletions packages/magicbell-js/docs/project-client/models/WorkflowRun.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# WorkflowRun

**Properties**

| Name | Type | Required | Description |
| :---------- | :---------------- | :------- | :---------- |
| createdAt | string | ❌ | |
| id | string | ❌ | |
| status | WorkflowRunStatus | ❌ | |
| workflowKey | string | ❌ | |

# WorkflowRunStatus

**Properties**

| Name | Type | Required | Description |
| :---------- | :----- | :------- | :---------- |
| completedAt | string | ❌ | |
| error | string | ❌ | |
| nextStep | number | ❌ | |
| startedAt | string | ❌ | |
| state | number | ❌ | |
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# WorkflowRunCollection

**Properties**

| Name | Type | Required | Description |
| :---- | :------------ | :------- | :---------- |
| data | WorkflowRun[] | ❌ | |
| links | Links | ❌ | |
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.broadcasts.listBroadcasts({
limit: 5,
limit: 10,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down Expand Up @@ -67,7 +67,22 @@ Creates a new broadcast. When a broadcast is created, it generates individual no
**Example Usage Code Snippet**

```typescript
import { Broadcast, Client, User } from 'magicbell-js/project-client';
import {
Broadcast,
BroadcastStatus,
Client,
Email,
Errors,
InApp,
MobilePush,
Overrides,
OverridesChannels,
Providers,
Sms,
StatusStatus,
Summary,
User,
} from 'magicbell-js/project-client';

(async () => {
const client = new Client({
Expand Down Expand Up @@ -143,7 +158,7 @@ import { Broadcast, Client, User } from 'magicbell-js/project-client';
const statusStatus = StatusStatus.ENQUEUED;

const summary: Summary = {
failures: 5,
failures: 10,
total: 10,
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Save the channels configuration for a given key.
**Example Usage Code Snippet**

```typescript
import { CategoryDeliveryConfig, Client } from 'magicbell-js/project-client';
import { CategoryDeliveryConfig, CategoryDeliveryConfigChannels, Channel, Client } from 'magicbell-js/project-client';

(async () => {
const client = new Client({
Expand All @@ -59,7 +59,7 @@ import { CategoryDeliveryConfig, Client } from 'magicbell-js/project-client';

const categoryDeliveryConfigChannels: CategoryDeliveryConfigChannels = {
channel: channel,
delay: 8,
delay: 9,
if: 'if',
};

Expand Down Expand Up @@ -139,7 +139,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.channels.listUserInboxTokens('user_id', {
limit: 5,
limit: 123,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down Expand Up @@ -355,7 +355,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.channels.listUserExpoTokens('user_id', {
limit: 10,
limit: 123,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down Expand Up @@ -463,7 +463,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.channels.listUserFcmTokens('user_id', {
limit: 8,
limit: 2,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down Expand Up @@ -571,7 +571,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.channels.listUserSlackTokens('user_id', {
limit: 1,
limit: 9,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down Expand Up @@ -679,7 +679,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.channels.listUserTeamsTokens('user_id', {
limit: 2,
limit: 9,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down Expand Up @@ -787,7 +787,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.channels.listUserWebPushTokens('user_id', {
limit: 8,
limit: 6,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ import { Client } from 'magicbell-js/project-client';
});

const { data } = await client.events.listEvents({
limit: 10,
limit: 4,
startingAfter: 'starting_after',
endingBefore: 'ending_before',
});
Expand Down
Loading
Loading