Skip to content
Draft
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
422 changes: 377 additions & 45 deletions .speakeasy/gen.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .speakeasy/gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ generation:
generateNewTests: false
skipResponseBodyAssertions: false
typescript:
version: 0.6.0
version: 0.6.1
acceptHeaderEnum: true
additionalDependencies:
dependencies:
Expand Down
10 changes: 5 additions & 5 deletions .speakeasy/workflow.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@ speakeasyVersion: 1.736.1
sources:
LaunchDarkly REST API:
sourceNamespace: launchdarkly-rest-api
sourceRevisionDigest: sha256:660091d01912e6441740c604153fd0de5dca3b7098818b06bdf27f928b20b4a1
sourceBlobDigest: sha256:320f0be8ba411906a7ef897a0ae7c0e86119d186cb70850c014c6552e5c08f39
sourceRevisionDigest: sha256:e7b2ab07f2495360eefd4e1aceec796f0994cdf05976415ea45b41f58768a5f6
sourceBlobDigest: sha256:819877dff442cc137c37a165ca8b949a41589a26f0d4b928870fb4a40d33b925
tags:
- latest
- "2.0"
targets:
launchdarkly-mcp-server:
source: LaunchDarkly REST API
sourceNamespace: launchdarkly-rest-api
sourceRevisionDigest: sha256:660091d01912e6441740c604153fd0de5dca3b7098818b06bdf27f928b20b4a1
sourceBlobDigest: sha256:320f0be8ba411906a7ef897a0ae7c0e86119d186cb70850c014c6552e5c08f39
sourceRevisionDigest: sha256:e7b2ab07f2495360eefd4e1aceec796f0994cdf05976415ea45b41f58768a5f6
sourceBlobDigest: sha256:819877dff442cc137c37a165ca8b949a41589a26f0d4b928870fb4a40d33b925
codeSamplesNamespace: launchdarkly-rest-api-typescript-code-samples
codeSamplesRevisionDigest: sha256:462d803ace535f1c269b2831ba1f3baf7fdac6fe7289fd8cacb33ee0d57fd3a5
codeSamplesRevisionDigest: sha256:c4cc8b6d9f832faf39b042bab82291448f7303b8e64c217235505ede65a6d991
workflow:
workflowVersion: 1.0.0
speakeasyVersion: 1.736.1
Expand Down
6 changes: 3 additions & 3 deletions FUNCTIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ specific category of applications.

```typescript
import { LaunchDarklyCore } from "@launchdarkly/mcp-server/core.js";
import { codeReferencesListRepositories } from "@launchdarkly/mcp-server/funcs/codeReferencesListRepositories.js";
import { approvalsList } from "@launchdarkly/mcp-server/funcs/approvalsList.js";

// Use `LaunchDarklyCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
Expand All @@ -29,12 +29,12 @@ const launchDarkly = new LaunchDarklyCore({
});

async function run() {
const res = await codeReferencesListRepositories(launchDarkly, {});
const res = await approvalsList(launchDarkly, {});
if (res.ok) {
const { value: result } = res;
console.log(result);
} else {
console.log("codeReferencesListRepositories failed:", res.error);
console.log("approvalsList failed:", res.error);
}
}

Expand Down
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,16 @@ For supported JavaScript runtimes, please consult [RUNTIMES.md](RUNTIMES.md).
* [getVariation](docs/sdks/aiconfigs/README.md#getvariation) - Get AI Config variation
* [updateVariation](docs/sdks/aiconfigs/README.md#updatevariation) - Update AI Config variation

### [Approvals](docs/sdks/approvals/README.md)

* [list](docs/sdks/approvals/README.md#list) - List approval requests
* [listForFlag](docs/sdks/approvals/README.md#listforflag) - List approval requests for a flag
* [createRequest](docs/sdks/approvals/README.md#createrequest) - Create approval request for a flag
* [getForFlag](docs/sdks/approvals/README.md#getforflag) - Get approval request for a flag
* [deleteFlagRequest](docs/sdks/approvals/README.md#deleteflagrequest) - Delete approval request for a flag
* [applyRequest](docs/sdks/approvals/README.md#applyrequest) - Apply approval request for a flag
* [reviewFlagRequest](docs/sdks/approvals/README.md#reviewflagrequest) - Review approval request for a flag

### [CodeReferences](docs/sdks/codereferences/README.md)

* [listRepositories](docs/sdks/codereferences/README.md#listrepositories) - List repositories
Expand Down
2 changes: 1 addition & 1 deletion USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const launchDarkly = new LaunchDarkly({
});

async function run() {
const result = await launchDarkly.codeReferences.listRepositories({});
const result = await launchDarkly.approvals.list({});

console.log(result);
}
Expand Down
19 changes: 19 additions & 0 deletions docs/models/components/aiconfigrep.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# AIConfigRep

## Example Usage

```typescript
import { AIConfigRep } from "@launchdarkly/mcp-server/models/components";

let value: AIConfigRep = {
key: "aiconfig-key-123abc",
name: "AI Config 1",
};
```

## Fields

| Field | Type | Required | Description | Example |
| ------------------------- | ------------------------- | ------------------------- | ------------------------- | ------------------------- |
| `key` | *string* | :heavy_check_mark: | The key of the AI Config | aiconfig-key-123abc |
| `name` | *string* | :heavy_check_mark: | The name of the AI Config | AI Config 1 |
16 changes: 16 additions & 0 deletions docs/models/components/conflict.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Conflict

## Example Usage

```typescript
import { Conflict } from "@launchdarkly/mcp-server/models/components";

let value: Conflict = {};
```

## Fields

| Field | Type | Required | Description |
| ------------------------------ | ------------------------------ | ------------------------------ | ------------------------------ |
| `instruction` | Record<string, *any*> | :heavy_minus_sign: | N/A |
| `reason` | *string* | :heavy_minus_sign: | Reason why the conflict exists |
19 changes: 19 additions & 0 deletions docs/models/components/copiedfromenv.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# CopiedFromEnv

## Example Usage

```typescript
import { CopiedFromEnv } from "@launchdarkly/mcp-server/models/components";

let value: CopiedFromEnv = {
key: "source-flag-key-123abc",
version: 1,
};
```

## Fields

| Field | Type | Required | Description | Example |
| ------------------------------ | ------------------------------ | ------------------------------ | ------------------------------ | ------------------------------ |
| `key` | *string* | :heavy_check_mark: | Key of feature flag copied | source-flag-key-123abc |
| `version` | *number* | :heavy_minus_sign: | Version of feature flag copied | 1 |
40 changes: 40 additions & 0 deletions docs/models/components/createflagconfigapprovalrequestrequest.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# CreateFlagConfigApprovalRequestRequest

## Example Usage

```typescript
import { CreateFlagConfigApprovalRequestRequest } from "@launchdarkly/mcp-server/models/components";

let value: CreateFlagConfigApprovalRequestRequest = {
comment: "optional comment",
description: "Requesting to update targeting",
instructions: [
{
"key": "<value>",
},
{
"key": "<value>",
},
],
notifyMemberIds: [
"1234a56b7c89d012345e678f",
],
notifyTeamKeys: [
"example-reviewer-team",
],
operatingOnId: "6297ed79dee7dc14e1f9a80c",
};
```

## Fields

| Field | Type | Required | Description | Example |
| ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
| `comment` | *string* | :heavy_minus_sign: | Optional comment describing the approval request | optional comment |
| `description` | *string* | :heavy_check_mark: | A brief description of the changes you're requesting | Requesting to update targeting |
| `instructions` | Record<string, *any*>[] | :heavy_check_mark: | N/A | |
| `notifyMemberIds` | *string*[] | :heavy_minus_sign: | An array of member IDs. These members are notified to review the approval request. | [<br/>"1234a56b7c89d012345e678f"<br/>] |
| `notifyTeamKeys` | *string*[] | :heavy_minus_sign: | An array of team keys. The members of these teams are notified to review the approval request. | [<br/>"example-reviewer-team"<br/>] |
| `executionDate` | *number* | :heavy_minus_sign: | N/A | |
| `operatingOnId` | *string* | :heavy_minus_sign: | The ID of a scheduled change. Include this if your <code>instructions</code> include editing or deleting a scheduled change. | 6297ed79dee7dc14e1f9a80c |
| `integrationConfig` | Record<string, *any*> | :heavy_minus_sign: | N/A | |
22 changes: 22 additions & 0 deletions docs/models/components/customworkflowmeta.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# CustomWorkflowMeta

## Example Usage

```typescript
import { CustomWorkflowMeta } from "@launchdarkly/mcp-server/models/components";

let value: CustomWorkflowMeta = {
name: "Example workflow name",
stage: {
index: 0,
name: "Stage 1",
},
};
```

## Fields

| Field | Type | Required | Description | Example |
| ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- |
| `name` | *string* | :heavy_minus_sign: | The name of the workflow stage that required this approval request | Example workflow name |
| `stage` | [components.CustomWorkflowStageMeta](../../models/components/customworkflowstagemeta.md) | :heavy_minus_sign: | N/A | |
19 changes: 19 additions & 0 deletions docs/models/components/customworkflowstagemeta.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# CustomWorkflowStageMeta

## Example Usage

```typescript
import { CustomWorkflowStageMeta } from "@launchdarkly/mcp-server/models/components";

let value: CustomWorkflowStageMeta = {
index: 0,
name: "Stage 1",
};
```

## Fields

| Field | Type | Required | Description | Example |
| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | ------------------------------------------ | ------------------------------------------ |
| `index` | *number* | :heavy_minus_sign: | The zero-based index of the workflow stage | 0 |
| `name` | *string* | :heavy_minus_sign: | The name of the workflow stage | Stage 1 |
30 changes: 28 additions & 2 deletions docs/models/components/environment.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,34 @@ let value: Environment = {
defaultTtl: 5,
secureMode: true,
access: {
denied: [],
allowed: [],
denied: [
{
action: "<value>",
reason: {
resources: [
"proj/*:env/*;qa_*:/flag/*",
],
actions: [
"*",
],
effect: "allow",
},
},
],
allowed: [
{
action: "<value>",
reason: {
resources: [
"proj/*:env/*;qa_*:/flag/*",
],
actions: [
"*",
],
effect: "allow",
},
},
],
},
defaultTrackEvents: false,
requireComments: true,
Expand Down
Loading