New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@aws/language-server-runtimes

Package Overview
Dependencies
Maintainers
0
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws/language-server-runtimes - npm Package Compare versions

Comparing version 0.2.15 to 0.2.16

protocol/identity-management.d.ts

4

package.json
{
"name": "@aws/language-server-runtimes",
"version": "0.2.15",
"version": "0.2.16",
"description": "Runtimes to host Language Servers for AWS",

@@ -37,3 +37,3 @@ "files": [

"@aws/language-server-runtimes-types": "^0.0.6",
"jose": "^5.7.0",
"jose": "^5.8.0",
"rxjs": "^7.8.1",

@@ -40,0 +40,0 @@ "vscode-languageserver": "^9.0.1",

@@ -203,2 +203,24 @@ # Language Server Runtimes

### Identity Management
The Identity Management feature is designed to centralize the management of authentication and identity-related functionality. The APIs consist of:
- Listing and managing user profiles and SSO sessions
- Obtaining valid SSO access tokens, handling the PKCE login flow as needed
- Controlling the lifetime and notifications for active SSO tokens
- Invalidating cached SSO tokens
#### Feature Specification
| Description | Method | Params | Method type | Response Type |
| ------------------------------------ | --------------------------------------- | -------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | -------------------------------- |
| List profiles | `aws/identity/listProfiles` | `ListProfilesParams` | [Request](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#requestMessage) | `ListProfilesResult` |
| Update profiles | `aws/identity/updateProfile` | `UpdateProfileParams` | [Request](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#requestMessage) | `UpdateProfileResult` |
| Get SSO token | `aws/identity/getSsoToken` | `GetSsoTokenParams` | [Request](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#requestMessage) | `GetSsoTokenResult` |
| Invalidate SSO token | `aws/identity/invalidateSsoToken` | `InvalidateSsoTokenParams` | [Request](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#requestMessage) | `InvalidateSsoTokenResult` |
| Update SSO Token Management config | `aws/identity/updateSsoTokenManagement` | `UpdateSsoTokenManagementParams` | [Request](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#requestMessage) | `UpdateSsoTokenManagementResult` |
| SSO token changed | `aws/identity/ssoTokenChanged` | `SsoTokenChangedParams` | [Notification](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#notificationMessage) | n/a |
Complete Identity Management parameter and result interfaces can be found in [identity-management.ts](src/protocol/identity-management.ts)
## Runtime Host Environments

@@ -205,0 +227,0 @@

@@ -56,2 +56,3 @@ "use strict";

}
const identity_management_1 = require("../protocol/identity-management");
/**

@@ -234,3 +235,11 @@ * The runtime for standalone LSP-based servers.

}
return s({ chat, credentialsProvider, lsp, workspace, telemetry, logging, runtime });
const identityManagement = {
onListProfiles: handler => lspConnection.onRequest(identity_management_1.listProfilesRequestType, handler),
onUpdateProfile: handler => lspConnection.onRequest(identity_management_1.updateProfilesRequestType, handler),
onGetSsoToken: handler => lspConnection.onRequest(identity_management_1.getSsoTokenRequestType, handler),
onInvalidateSsoToken: handler => lspConnection.onRequest(identity_management_1.invalidateSsoTokenRequestType, handler),
onUpdateSsoTokenManagement: handler => lspConnection.onRequest(identity_management_1.updateSsoTokenManagementRequestType, handler),
sendSsoTokenChanged: params => lspConnection.sendNotification(identity_management_1.ssoTokenChangedRequestType, params),
};
return s({ chat, credentialsProvider, lsp, workspace, telemetry, logging, runtime, identityManagement });
});

@@ -237,0 +246,0 @@ // Free up any resources or threads used by Servers

@@ -20,2 +20,3 @@ "use strict";

const lspServer_1 = require("./lsp/router/lspServer");
const identity_management_1 = require("../protocol/identity-management");
// TODO: testing rig for runtimes

@@ -125,3 +126,11 @@ const webworker = (props) => {

};
return s({ chat, credentialsProvider, lsp, workspace, telemetry, logging, runtime });
const identityManagement = {
onListProfiles: handler => lspConnection.onRequest(identity_management_1.listProfilesRequestType, handler),
onUpdateProfile: handler => lspConnection.onRequest(identity_management_1.updateProfilesRequestType, handler),
onGetSsoToken: handler => lspConnection.onRequest(identity_management_1.getSsoTokenRequestType, handler),
onInvalidateSsoToken: handler => lspConnection.onRequest(identity_management_1.invalidateSsoTokenRequestType, handler),
onUpdateSsoTokenManagement: handler => lspConnection.onRequest(identity_management_1.updateSsoTokenManagementRequestType, handler),
sendSsoTokenChanged: params => lspConnection.sendNotification(identity_management_1.ssoTokenChangedRequestType, params),
};
return s({ chat, credentialsProvider, lsp, workspace, telemetry, logging, runtime, identityManagement });
});

@@ -128,0 +137,0 @@ // Free up any resources or threads used by Servers

import { Logging, Lsp, Telemetry, Workspace, CredentialsProvider, Chat, Runtime } from '.';
import { IdentityManagement } from './identity-management';
/**

@@ -25,2 +26,3 @@ * Servers are used to provide features to the client.

runtime: Runtime;
identityManagement: IdentityManagement;
}) => () => void;
import { Server, CredentialsProvider, Logging, Lsp, Telemetry, Workspace, Chat, Runtime } from '../server-interface';
import { StubbedInstance } from 'ts-sinon';
import { CancellationToken, CompletionParams, DidChangeTextDocumentParams, DidOpenTextDocumentParams, DocumentFormattingParams, ExecuteCommandParams, HoverParams, InlineCompletionParams, SemanticTokensParams, TextDocument, SignatureHelpParams } from '../protocol';
import { IdentityManagement } from '../server-interface/identity-management';
/**

@@ -28,2 +29,3 @@ * A test helper package to test Server implementations. Accepts a single callback

runtime: StubbedInstance<Runtime>;
identityManagement: StubbedInstance<IdentityManagement>;
private disposables;

@@ -30,0 +32,0 @@ constructor();

@@ -37,2 +37,3 @@ "use strict";

this.runtime = (0, ts_sinon_1.stubInterface)();
this.identityManagement = (0, ts_sinon_1.stubInterface)();
this.workspace.getTextDocument.callsFake((uri) => __awaiter(this, void 0, void 0, function* () { return this.documents[uri]; }));

@@ -39,0 +40,0 @@ }

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc