Skip to content

Releases: nylas/javascript

@nylas/[email protected]

21 Oct 12:32
f01da14

Choose a tag to compare

Minor Changes

  • bf03a1e: Export CodeExchangeMethod and CodeExchangeParams types for custom code exchange implementations.

@nylas/[email protected]

20 Oct 16:12
1fb0a7f

Choose a tag to compare

Minor Changes

  • 75d6769: - Added IdentityProviderTokenCallback type for providing JWT tokens
    • Added optional identityProviderToken callback to ConnectConfig
    • Token exchange now uses JSON format instead of form-encoded requests
    • Added idp_claims field to token exchange when IDP token is provided

@nylas/[email protected]

07 Oct 19:34
f5ae27f

Choose a tag to compare

Major Changes

  • 2408953: Add custom code exchange functionality for enhanced security.

    Usage

    // Handle code exchange on your backend
    const nylasConnect = new NylasConnect({
      clientId: "your-client-id",
      redirectUri: "http://localhost:3000/callback",
      codeExchange: async (params) => {
        const response = await fetch("/api/auth/exchange", {
          method: "POST",
          body: JSON.stringify(params),
        });
        return await response.json();
      },
    });
    
    // Use normally - custom exchange is called automatically
    const result = await nylasConnect.connect({ method: "popup" });

@nylas/[email protected]

02 Oct 13:29
022fbaa

Choose a tag to compare

Minor Changes

  • 356ac8f: Add automatic API URL version suffix handling

    The NylasConnect client now automatically appends /v3 to API URLs that don't already have a version suffix. This ensures all API calls use versioned endpoints while preserving any explicitly set versions.

    Features:

    • Automatically appends /v3 to API URLs without version suffixes
    • Preserves existing version suffixes (e.g., /v1, /v2, /v10)
    • Handles trailing slashes correctly
    • Works with custom API URLs and regional endpoints

    Examples:

    • https://api.us.nylas.comhttps://api.us.nylas.com/v3
    • https://api.us.nylas.com/v2https://api.us.nylas.com/v2 (unchanged)
    • https://custom.api.comhttps://custom.api.com/v3

    This change is backward compatible and doesn't affect existing functionality.

@nylas/[email protected]

19 Sep 12:15
eabac56

Choose a tag to compare

Patch Changes

  • 2ef30c8: Fix NPM publishing configuration by adding publishConfig for scoped package access