<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [git-documentdb](./git-documentdb.md) &gt; [JsonDocWithMetadata](./git-documentdb.jsondocwithmetadata.md)

## JsonDocWithMetadata type

Type for a JSON document with metadata

<b>Signature:</b>

```typescript
export declare type JsonDocWithMetadata = DocMetadata & {
    doc?: JsonDoc;
};
```
<b>References:</b> [DocMetadata](./git-documentdb.docmetadata.md)<!-- -->, [JsonDoc](./git-documentdb.jsondoc.md)

## Remarks

- id: id of a document. (You might be confused. Underscored '\_id' is used only in a [JsonDoc](./git-documentdb.jsondoc.md) type. In other cases, 'id' is used. This is a custom of PouchDB/CouchDB.)

- file\_sha: SHA-1 hash of Git object (40 characters)

- doc: JsonDoc which has a '\_id' value. The value of 'id' and 'doc.\_id' are the same.

