Skip to content

Commit abb9d4e

Browse files
Type definition for arrays
1 parent cc0fd15 commit abb9d4e

File tree

7 files changed

+60
-22
lines changed

7 files changed

+60
-22
lines changed

src/tools/fetch-company.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,16 +128,19 @@ export class FetchCompanyTool extends OperationTool<TFetchCompanyParams, unknown
128128
type: 'array',
129129
description:
130130
'Optional. Array of free-form strings representing locations. Matches if employee is located in any of the listed locations.',
131+
items: { type: 'string' },
131132
},
132133
industries: {
133134
type: 'array',
134135
description:
135136
'Optional. Array of enums representing industries. Matches if employee works in any of the listed industries. Takes specific values available in the LinkedIn interface.',
137+
items: { type: 'string' },
136138
},
137139
schools: {
138140
type: 'array',
139141
description:
140142
'Optional. Array of institution names. Matches if employee currently attends or previously attended any of the listed institutions.',
143+
items: { type: 'string' },
141144
},
142145
},
143146
},

src/tools/nv-fetch-company.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,27 +83,34 @@ export class NvFetchCompanyTool extends OperationTool<TNvFetchCompanyParams, unk
8383
type: 'array',
8484
description:
8585
"Optional. Array of job position names. Matches if employee's current position is any of the listed options.",
86+
items: { type: 'string' },
8687
},
8788
locations: {
8889
type: 'array',
8990
description:
9091
'Optional. Array of free-form strings representing locations. Matches if employee is located in any of the listed locations.',
92+
items: { type: 'string' },
9193
},
9294
industries: {
9395
type: 'array',
9496
description:
9597
'Optional. Array of enums representing industries. Matches if employee works in any of the listed industries. Takes specific values available in the LinkedIn interface.',
98+
items: { type: 'string' },
9699
},
97100
schools: {
98101
type: 'array',
99102
description:
100103
'Optional. Array of institution names. Matches if employee currently attends or previously attended any of the listed institutions.',
104+
items: { type: 'string' },
101105
},
102106
yearsOfExperiences: {
103107
type: 'array',
104108
description:
105109
"Optional. Array of enums representing professional experience. Matches if employee's experience falls within any of the listed ranges.",
106-
enum: ['lessThanOne', 'oneToTwo', 'threeToFive', 'sixToTen', 'moreThanTen'],
110+
items: {
111+
type: 'string',
112+
enum: ['lessThanOne', 'oneToTwo', 'threeToFive', 'sixToTen', 'moreThanTen'],
113+
},
107114
},
108115
},
109116
},

src/tools/nv-search-companies.ts

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -64,26 +64,31 @@ export class NvSearchCompaniesTool extends OperationTool<TNvSearchCompaniesParam
6464
type: 'array',
6565
description:
6666
'Optional. Array of enums representing employee count ranges. Matches if company size falls within any of the listed ranges.',
67-
enum: [
68-
'1-10',
69-
'11-50',
70-
'51-200',
71-
'201-500',
72-
'501-1000',
73-
'1001-5000',
74-
'5001-10000',
75-
'10001+',
76-
],
67+
items: {
68+
type: 'string',
69+
enum: [
70+
'1-10',
71+
'11-50',
72+
'51-200',
73+
'201-500',
74+
'501-1000',
75+
'1001-5000',
76+
'5001-10000',
77+
'10001+',
78+
],
79+
},
7780
},
7881
locations: {
7982
type: 'array',
8083
description:
8184
'Optional. Array of free-form strings representing locations. Matches if company is headquartered in any of the listed locations.',
85+
items: { type: 'string' },
8286
},
8387
industries: {
8488
type: 'array',
8589
description:
8690
'Optional. Array of enums representing industries. Matches if company works in any of the listed industries. Takes specific values available in the LinkedIn interface.',
91+
items: { type: 'string' },
8792
},
8893
annualRevenue: {
8994
type: 'object',

src/tools/nv-search-people.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,32 +63,40 @@ export class NvSearchPeopleTool extends OperationTool<TNvSearchPeopleParams, unk
6363
type: 'array',
6464
description:
6565
'Optional. Array of free-form strings representing locations. Matches if person is located in any of the listed locations.',
66+
items: { type: 'string' },
6667
},
6768
industries: {
6869
type: 'array',
6970
description:
7071
'Optional. Array of enums representing industries. Matches if person works in any of the listed industries. Takes specific values available in the LinkedIn interface.',
72+
items: { type: 'string' },
7173
},
7274
currentCompanies: {
7375
type: 'array',
7476
description:
7577
'Optional. Array of company names. Matches if person currently works at any of the listed companies.',
78+
items: { type: 'string' },
7679
},
7780
previousCompanies: {
7881
type: 'array',
7982
description:
8083
'Optional. Array of company names. Matches if person previously worked at any of the listed companies.',
84+
items: { type: 'string' },
8185
},
8286
schools: {
8387
type: 'array',
8488
description:
8589
'Optional. Array of institution names. Matches if person currently attends or previously attended any of the listed institutions.',
90+
items: { type: 'string' },
8691
},
8792
yearsOfExperiences: {
8893
type: 'array',
8994
description:
9095
"Optional. Array of enums representing professional experience. Matches if person's experience falls within any of the listed ranges.",
91-
enum: ['lessThanOne', 'oneToTwo', 'threeToFive', 'sixToTen', 'moreThanTen'],
96+
items: {
97+
type: 'string',
98+
enum: ['lessThanOne', 'oneToTwo', 'threeToFive', 'sixToTen', 'moreThanTen'],
99+
},
92100
},
93101
},
94102
},

src/tools/retrieve-connections.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,26 +64,31 @@ export class RetrieveConnectionsTool extends OperationTool<
6464
type: 'array',
6565
description:
6666
'Optional. Array of free-form strings representing locations. Matches if person is located in any of the listed locations.',
67+
items: { type: 'string' },
6768
},
6869
industries: {
6970
type: 'array',
7071
description:
7172
'Optional. Array of enums representing industries. Matches if person works in any of the listed industries. Takes specific values available in the LinkedIn interface.',
73+
items: { type: 'string' },
7274
},
7375
currentCompanies: {
7476
type: 'array',
7577
description:
7678
'Optional. Array of company names. Matches if person currently works at any of the listed companies.',
79+
items: { type: 'string' },
7780
},
7881
previousCompanies: {
7982
type: 'array',
8083
description:
8184
'Optional. Array of company names. Matches if person previously worked at any of the listed companies.',
85+
items: { type: 'string' },
8286
},
8387
schools: {
8488
type: 'array',
8589
description:
8690
'Optional. Array of institution names. Matches if person currently attends or previously attended any of the listed institutions.',
91+
items: { type: 'string' },
8792
},
8893
},
8994
},

src/tools/search-companies.ts

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -58,26 +58,31 @@ export class SearchCompaniesTool extends OperationTool<TSearchCompaniesParams, u
5858
type: 'array',
5959
description:
6060
'Optional. Array of enums representing employee count ranges. Matches if company size falls within any of the listed ranges.',
61-
enum: [
62-
'1-10',
63-
'11-50',
64-
'51-200',
65-
'201-500',
66-
'501-1000',
67-
'1001-5000',
68-
'5001-10000',
69-
'10001+',
70-
],
61+
items: {
62+
type: 'string',
63+
enum: [
64+
'1-10',
65+
'11-50',
66+
'51-200',
67+
'201-500',
68+
'501-1000',
69+
'1001-5000',
70+
'5001-10000',
71+
'10001+',
72+
],
73+
},
7174
},
7275
locations: {
7376
type: 'array',
7477
description:
7578
'Optional. Array of free-form strings representing locations. Matches if company is headquartered in any of the listed locations.',
79+
items: { type: 'string' },
7680
},
7781
industries: {
7882
type: 'array',
7983
description:
8084
'Optional. Array of enums representing industries. Matches if company works in any of the listed industries. Takes specific values available in the LinkedIn interface.',
85+
items: { type: 'string' },
8186
},
8287
},
8388
},

src/tools/search-people.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,26 +62,31 @@ export class SearchPeopleTool extends OperationTool<TSearchPeopleParams, unknown
6262
type: 'array',
6363
description:
6464
'Optional. Array of free-form strings representing locations. Matches if person is located in any of the listed locations.',
65+
items: { type: 'string' },
6566
},
6667
industries: {
6768
type: 'array',
6869
description:
6970
'Optional. Array of enums representing industries. Matches if person works in any of the listed industries. Takes specific values available in the LinkedIn interface.',
71+
items: { type: 'string' },
7072
},
7173
currentCompanies: {
7274
type: 'array',
7375
description:
7476
'Optional. Array of company names. Matches if person currently works at any of the listed companies.',
77+
items: { type: 'string' },
7578
},
7679
previousCompanies: {
7780
type: 'array',
7881
description:
7982
'Optional. Array of company names. Matches if person previously worked at any of the listed companies.',
83+
items: { type: 'string' },
8084
},
8185
schools: {
8286
type: 'array',
8387
description:
8488
'Optional. Array of institution names. Matches if person currently attends or previously attended any of the listed institutions.',
89+
items: { type: 'string' },
8590
},
8691
},
8792
},

0 commit comments

Comments
 (0)