Skip to content

A MongoDB client compatible with Swift Cloud and Fastly Compute@Edge

License

Notifications You must be signed in to change notification settings

swift-cloud/MongoDB

Repository files navigation

MongoDB

A MongoDB Atlas Data API library compatible with all Apple platforms, Swift Cloud and Fastly Compute@Edge

Usage

import MongoDB

let client = MongoClient(
    endpoint: "https://us-east-1.aws.data.mongodb-api.com/app/data-12345/endpoint/data/v1",
    cluster: "cluster-prod",
    database: "test",
    apiKey: "..."
)

let user = try await client
    .collection("users")
    .send(.findOne())
    .document(User.self)

About

A MongoDB client compatible with Swift Cloud and Fastly Compute@Edge

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages