mirror of
https://github.com/ION606/linkedin-api.git
synced 2026-05-14 22:06:54 +00:00
renamed function
This commit is contained in:
@@ -192,6 +192,8 @@ export default class linkedInAPIClass {
|
||||
* @param {Array<Number>?} numEmp
|
||||
* @param {Number?} [start=0]
|
||||
* @param {boolean?} [castToClass=true] whether the function should return a list of Company classes or just raw JSON
|
||||
* @param {boolean} [excludeGeneric=false]
|
||||
* @returns {Promise<[SocialActivityCounts | Group | Company | GenericEntity]>}
|
||||
*/
|
||||
async searchCompanies(keyword, numEmp, start = 0, castToClass = true, excludeGeneric = false) {
|
||||
let urlExt = `variables=(start:${start},origin:GLOBAL_SEARCH_HEADER,query:(keywords:${keyword},flagshipSearchIntent:SEARCH_SRP,queryParameters:List((key:resultType,value:List(COMPANIES))),includeFiltersInResponse:false))`;
|
||||
|
||||
+1
-1
@@ -45,7 +45,7 @@ export class Company {
|
||||
* @param {string} name
|
||||
* @param {boolean} raw
|
||||
*/
|
||||
getEmployees = (name, limit=1000, raw=false) => this.#APIRef.searchEmployees(name, limit, !raw, [this.urn]);
|
||||
searchEmployees = (name, limit=1000, raw=false) => this.#APIRef.searchEmployees(name, limit, !raw, [this.urn]);
|
||||
|
||||
async getInfo() {
|
||||
const toAdd = `q=universalName&universalName=${this.urn}`;
|
||||
|
||||
Vendored
+2
-2
@@ -162,8 +162,8 @@ export default class linkedInAPIClass {
|
||||
* @param numEmp Array of numbers representing company sizes
|
||||
* @param start Pagination start
|
||||
* @param castToClass Whether to cast the result to Company classes or return raw JSON
|
||||
* @param excludeGeneric Whether to exclude generic results
|
||||
* @returns Promise resolving to either an array of Company or raw JSON
|
||||
* @param excludeGeneric Whether to exclude the "generic" class
|
||||
* @returns Promise resolving to either an array of SocialActivityCounts or Group or Company or GenericEntity
|
||||
*/
|
||||
searchCompanies(keyword: string, numEmp?: number[], start?: number, castToClass?: boolean, excludeGeneric?: boolean): Promise<[SocialActivityCounts | Group | Company | GenericEntity]>;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user