Skip to content

Commit 57997e5

Browse files
committed
Create entry docs update
1 parent e2e256b commit 57997e5

File tree

5 files changed

+17
-33
lines changed

5 files changed

+17
-33
lines changed

lib/stack/contentType/entry/index.js

+6-1
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,12 @@ export function Entry (http, data) {
277277
* const client = contentstack.client()
278278
* const entry = {
279279
* title: 'Sample Entry',
280-
* url: '/sampleEntry'
280+
* url: '/sampleEntry',
281+
* file: 'asset_uid', // for single asset pass asset uid to entry asset field value
282+
* multiple_file = ['asset_uid_1', 'asset_uid_2'], // for multiple asset pass array of asset uid to entry asset field values
283+
* reference: reference.uid, // for single reference pass reference uid to entry reference field value
284+
* multiple_reference: ['reference_uid_1', 'reference_uid_2'], // for multiple reference pass array of reference uid to entry reference field values
285+
* multiple_content_type_reference: [{_content_type_uid: 'content_type_uid_1', uid: 'reference_uid_1'}, {_content_type_uid: 'content_type_uid_2', uid: 'reference_uid_2'}] // for multiple reference pass array of reference uid to entry reference field values
281286
* }
282287
* client.stack().contentType('content_type_uid').entry().create({ entry })
283288
* .then((entry) => console.log(entry))

types/stack/deliveryToken/index.ts

+7-1
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,11 @@ export interface Scope {
1717
module: string
1818
environments?: Array<string>
1919
locales?: Array<string>
20-
acl: any
20+
acl: ACL
21+
}
22+
export interface ACL extends AnyProperty {
23+
read?: boolean
24+
write?: boolean
25+
create?: boolean
26+
update?: boolean
2127
}

types/stack/roles/index.d.ts

-29
This file was deleted.

types/stack/workflow/index.d.ts

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { ContentstackCollection } from "../../contentstackCollection";
12
import { AnyProperty, SystemFields } from "../../utility/fields";
23
import { Creatable, SystemFunction } from "../../utility/operations";
34
import { PublishRule, PublishRules } from "./publishRules";

types/stack/workflow/publishRules.d.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
import { ContentstackCollection } from "../../contentstackCollection";
12
import { AnyProperty, SystemFields } from "../../utility/fields";
23
import { Creatable, SystemFunction } from "../../utility/operations";
34

4-
export interface PublishRule extends SystemFields, SystemFunction<PublishRuls> {
5+
export interface PublishRule extends SystemFields, SystemFunction<PublishRules> {
56
}
67

7-
export interface PublishRules extends Creatable<PublishRule, {publishing_rule: PublishRuleData}> {
8+
export interface PublishRules extends Creatable<PublishRule, {publishing_rule: PublishRulesData}> {
89
fetchAll(param?: AnyProperty): Promise<ContentstackCollection<PublishRule>>
910
}
1011

0 commit comments

Comments
 (0)