Skip to main content
The Deno 2 Release Candidate is here
Learn more
Latest
method Bson.ObjectId.generate
Re-export
import { Bson } from "https://deno.land/x/model@v1.2/dependencies/mongo.ts";
const { ObjectId } = Bson;

Generate a 12 byte id buffer used in ObjectId's

Parameters

optional
time: number
  • pass in a second based timestamp.

Returns

Uint8Array