@onereach/types-contacts-api 1.37.3 → 1.37.4-beta.809.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.ts +34 -5
  2. package/package.json +2 -3
package/dist/index.ts CHANGED
@@ -42,6 +42,16 @@ export interface CreateContactDto {
42
42
  data: FieldValueRequestDto[];
43
43
  }
44
44
 
45
+ export interface DeleteContactMultiParamsDto extends DeleteContactParamsDto {
46
+ ids?: string[];
47
+ contact_book: string;
48
+ all?: true;
49
+ }
50
+
51
+ export interface DeleteContactParamsDto {
52
+ contact_book: string;
53
+ }
54
+
45
55
  export interface MergeContactParamsDto {
46
56
  contact_book: string;
47
57
  mergeContactId: string;
@@ -87,8 +97,8 @@ export interface ContactBookResponseDto extends CreateContactBookDto {
87
97
  id: string;
88
98
  created_at: Date;
89
99
  updated_at: Date;
90
- contacts?: ContactResponseDto[];
91
- crossAccountMeta: CrossAccountMetaDto | null;
100
+ contactsCount: number;
101
+ status?: SharedBookStatus;
92
102
  }
93
103
 
94
104
  export interface CreateContactBookDto {
@@ -97,13 +107,15 @@ export interface CreateContactBookDto {
97
107
  schemaPresets?: SchemaPresetResponseDto[];
98
108
  }
99
109
 
110
+ export interface UpdateContactBookDto extends ReturnType<typeof PartialType<CreateContactBookDto>> {
111
+ }
112
+
100
113
  export interface CrossAccountMetaDto {
101
114
  id: string;
102
115
  created_at: Date;
103
- is_approved: boolean;
116
+ updated_at: Date;
104
117
  account_name: string;
105
118
  account_id: string;
106
- approved_by: string;
107
119
  original_book_id: string;
108
120
  }
109
121
 
@@ -111,7 +123,24 @@ export interface ShareContactBookParamsDto {
111
123
  targetAccountId: string;
112
124
  }
113
125
 
114
- export interface UpdateContactBookDto extends ReturnType<typeof PartialType<CreateContactBookDto>> {
126
+ export interface SharedBookMetaParamsDto {
127
+ accountId: string;
128
+ bookIds: string;
129
+ }
130
+
131
+ export interface SharedBookResponseDto {
132
+ approved_by?: string;
133
+ status: SharedBookStatus;
134
+ target_account: string;
135
+ contact_book: string;
136
+ }
137
+
138
+ export enum SharedBookStatus {
139
+ pending = 'pending',
140
+ shared = 'shared',
141
+ canceled = 'canceled',
142
+ deletedFromTarget = 'deletedFromTarget',
143
+ deletedFromSource = 'deletedFromSource'
115
144
  }
116
145
 
117
146
  export interface FieldSchemaListDto extends ListApiResponse {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@onereach/types-contacts-api",
3
3
  "description": "Generated types for Contacts Api",
4
- "version": "1.37.3",
4
+ "version": "1.37.4-beta.809.0",
5
5
  "author": "OneReach.ai",
6
6
  "main": "./dist/index.ts",
7
7
  "publishConfig": {
@@ -17,6 +17,5 @@
17
17
  "@types/node": "^16.0.0",
18
18
  "ts-morph": "^15.1.0",
19
19
  "ts-node": "^10.0.0"
20
- },
21
- "gitHead": "d1978bed8a4b464619df01680a2e4e9f2aa3945f"
20
+ }
22
21
  }