Conflict class
Properties
container | |
id | |
url | Returns a reference URL to the resource. Used for linking in Permissions. |
Methods
delete(Request |
Delete the given ConflictDefinition. Example
|
read(Request |
Read the ConflictDefinition for the given Conflict. Example
|
Property Details
container
id
id: string
Property Value
string
url
Returns a reference URL to the resource. Used for linking in Permissions.
string url
Property Value
string
Method Details
delete(RequestOptions)
Delete the given ConflictDefinition.
Example
import { CosmosClient } from "@azure/cosmos";
const endpoint = "https://your-account.documents.azure.com";
const key = "<database account masterkey>";
const client = new CosmosClient({ endpoint, key });
const { database } = await client.databases.createIfNotExists({ id: "Test Database" });
const container = database.container("Test Container");
await container.conflict("<conflict-id>").delete();
function delete(options?: RequestOptions): Promise<ConflictResponse>
Parameters
- options
- RequestOptions
Returns
Promise<ConflictResponse>
read(RequestOptions)
Read the ConflictDefinition for the given Conflict.
Example
import { CosmosClient } from "@azure/cosmos";
const endpoint = "https://your-account.documents.azure.com";
const key = "<database account masterkey>";
const client = new CosmosClient({ endpoint, key });
const { database } = await client.databases.createIfNotExists({ id: "Test Database" });
const container = database.container("Test Container");
const { resource: conflict } = await container.conflict("<conflict-id>").read();
function read(options?: RequestOptions): Promise<ConflictResponse>
Parameters
- options
- RequestOptions
Returns
Promise<ConflictResponse>