Skip to content

Feature req: identity-based connection #73

@kumkee

Description

@kumkee

Do you only support Connection-String connections?

Please add support for identity-based connection.

In the upstream, this is done using the DefaultAzureCredential class provided by the Azure.Identity client library.

This would be a function called Cosmos.fromCredential which works like

open Microsoft.Azure.Cosmos
open Azure.Identity
open FSharp.CosmosDb

let credential = new DefaultAzureCredential()

let insertUsers data =
    credential 
    |> Cosmos.fromCredential
    |> Cosmos.database "UserDb"
    |> Cosmos.container "UserContainer"
    |> Cosmos.insertMany<User> data
    |> Cosmos.execAsync

Many thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions