Skip to content

Commit c3e7049

Browse files
2 parents 3d3c36c + ec15d9b commit c3e7049

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

types/dynamics-web-api-callbacks.d.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -869,11 +869,11 @@ declare namespace DynamicsWebApi {
869869
key?: string;
870870
}
871871

872-
interface CreateRequest extends CRUDRequest {
872+
interface CreateRequest<T = any> extends CRUDRequest {
873873
/**v.1.3.4+ Web API v9+ only! Boolean that enables duplicate detection. */
874874
duplicateDetection?: boolean;
875875
/**A JavaScript object with properties corresponding to the logical name of entity attributes(exceptions are lookups and single - valued navigation properties). */
876-
entity?: any;
876+
entity?: T;
877877
/**An array of Expand Objects(described below the table) representing the $expand OData System Query Option value to control which related records are also returned. */
878878
expand?: Expand[];
879879
/**Sets Prefer header with value "odata.include-annotations=" and the specified annotation.Annotations provide additional information about lookups, options sets and other complex attribute types. */
@@ -888,11 +888,11 @@ declare namespace DynamicsWebApi {
888888
contentId?: string;
889889
}
890890

891-
interface UpdateRequestBase extends CRUDRequest {
891+
interface UpdateRequestBase<T = any> extends CRUDRequest {
892892
/**v.1.3.4+ Web API v9+ only! Boolean that enables duplicate detection. */
893893
duplicateDetection?: boolean;
894894
/**A JavaScript object with properties corresponding to the logical name of entity attributes(exceptions are lookups and single - valued navigation properties). */
895-
entity?: any;
895+
entity?: T;
896896
/**An array of Expand Objects(described below the table) representing the $expand OData System Query Option value to control which related records are also returned. */
897897
expand?: Expand[];
898898
/**Sets If-Match header value that enables to use conditional retrieval or optimistic concurrency in applicable requests.*/
@@ -913,12 +913,12 @@ declare namespace DynamicsWebApi {
913913
navigationPropertyKey?: string;
914914
}
915915

916-
interface UpdateRequest extends UpdateRequestBase {
916+
interface UpdateRequest<T = any> extends UpdateRequestBase<T> {
917917
/**If set to 'true', DynamicsWebApi adds a request header 'MSCRM.MergeLabels: true'. Default value is 'false' */
918918
mergeLabels?: boolean;
919919
}
920920

921-
interface UpsertRequest extends UpdateRequestBase {
921+
interface UpsertRequest<T = any> extends UpdateRequestBase<T> {
922922
/**Sets If-None-Match header value that enables to use conditional retrieval in applicable requests. */
923923
ifnonematch?: string;
924924
}

types/dynamics-web-api.d.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -547,11 +547,11 @@ declare namespace DynamicsWebApi {
547547
key?: string;
548548
}
549549

550-
interface CreateRequest extends CRUDRequest {
550+
interface CreateRequest<T = any> extends CRUDRequest {
551551
/**v.1.3.4+ Web API v9+ only! Boolean that enables duplicate detection. */
552552
duplicateDetection?: boolean;
553553
/**A JavaScript object with properties corresponding to the logical name of entity attributes(exceptions are lookups and single-valued navigation properties). */
554-
entity?: any;
554+
entity?: T;
555555
/**An array of Expand Objects(described below the table) representing the $expand OData System Query Option value to control which related records are also returned. */
556556
expand?: Expand[];
557557
/**Sets Prefer header with value "odata.include-annotations=" and the specified annotation.Annotations provide additional information about lookups, options sets and other complex attribute types. */
@@ -566,11 +566,11 @@ declare namespace DynamicsWebApi {
566566
contentId?: string;
567567
}
568568

569-
interface UpdateRequestBase extends CRUDRequest {
569+
interface UpdateRequestBase<T = any> extends CRUDRequest {
570570
/**v.1.3.4+ Web API v9+ only! Boolean that enables duplicate detection. */
571571
duplicateDetection?: boolean;
572572
/**A JavaScript object with properties corresponding to the logical name of entity attributes(exceptions are lookups and single-valued navigation properties). */
573-
entity?: any;
573+
entity?: T;
574574
/**An array of Expand Objects(described below the table) representing the $expand OData System Query Option value to control which related records are also returned. */
575575
expand?: Expand[];
576576
/**Sets If-Match header value that enables to use conditional retrieval or optimistic concurrency in applicable requests.*/
@@ -591,12 +591,12 @@ declare namespace DynamicsWebApi {
591591
navigationPropertyKey?: string;
592592
}
593593

594-
interface UpdateRequest extends UpdateRequestBase {
594+
interface UpdateRequest<T = any> extends UpdateRequestBase<T> {
595595
/**If set to 'true', DynamicsWebApi adds a request header 'MSCRM.MergeLabels: true'. Default value is 'false' */
596596
mergeLabels?: boolean;
597597
}
598598

599-
interface UpsertRequest extends UpdateRequestBase {
599+
interface UpsertRequest<T = any> extends UpdateRequestBase<T> {
600600
/**Sets If-None-Match header value that enables to use conditional retrieval in applicable requests. */
601601
ifnonematch?: string;
602602
}

0 commit comments

Comments
 (0)