need4deed-sdk 0.0.41 → 0.0.43
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.
- package/dist/types/api/address.d.ts +5 -0
- package/dist/types/api/address.js +2 -0
- package/dist/types/api/agent.d.ts +11 -0
- package/dist/types/api/agent.js +8 -0
- package/dist/types/api/common.d.ts +2 -0
- package/dist/types/api/index.d.ts +1 -0
- package/dist/types/api/index.js +1 -0
- package/dist/types/api/opportunity.d.ts +19 -4
- package/dist/types/api/organization.d.ts +4 -0
- package/dist/types/api/organization.js +2 -0
- package/dist/types/api/person.d.ts +8 -0
- package/dist/types/api/person.js +9 -0
- package/dist/types/api/volunteer.d.ts +4 -8
- package/dist/types/api/volunteer.js +2 -7
- package/dist/types/utils.d.ts +1 -0
- package/dist/types/utils.js +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ApiOrganizationGet } from "./organization";
|
|
2
|
+
import { ApiPersonGet } from "./person";
|
|
3
|
+
export declare enum AgentType {
|
|
4
|
+
RAC = "rac",
|
|
5
|
+
NGO = "ngo"
|
|
6
|
+
}
|
|
7
|
+
export interface ApiAgentGet {
|
|
8
|
+
type: AgentType;
|
|
9
|
+
operator: ApiPersonGet | ApiOrganizationGet;
|
|
10
|
+
contact: ApiPersonGet;
|
|
11
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Lang } from "../core";
|
|
2
|
+
import { PartialBy } from "../utils";
|
|
2
3
|
export type OptionTitle = Partial<{
|
|
3
4
|
[key in Lang]: string;
|
|
4
5
|
}>;
|
|
@@ -7,3 +8,4 @@ export interface Option {
|
|
|
7
8
|
id: OptionId;
|
|
8
9
|
title: OptionTitle;
|
|
9
10
|
}
|
|
11
|
+
export type OptionById = PartialBy<Option, "title">;
|
package/dist/types/api/index.js
CHANGED
|
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./agent"), exports);
|
|
17
18
|
__exportStar(require("./appreciation"), exports);
|
|
18
19
|
__exportStar(require("./comment"), exports);
|
|
19
20
|
__exportStar(require("./common"), exports);
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { Id } from "..";
|
|
2
|
-
import {
|
|
2
|
+
import { ApiAddressGet } from "./address";
|
|
3
|
+
import { OptionById, OptionId } from "./common";
|
|
3
4
|
import { ApiLanguage } from "./language";
|
|
5
|
+
import { PrefferedCommunicationType } from "./person";
|
|
4
6
|
import { VolunteerStateTypeType } from "./volunteer";
|
|
5
7
|
export declare enum OpportunityType {
|
|
6
8
|
GENERAL = "volunteering",
|
|
@@ -53,6 +55,18 @@ export interface Opportunity {
|
|
|
53
55
|
category_id: OptionId;
|
|
54
56
|
last_edited_time_notion?: string;
|
|
55
57
|
}
|
|
58
|
+
export interface ApiOpportunityAgent {
|
|
59
|
+
contactPerson: {
|
|
60
|
+
name: string;
|
|
61
|
+
phone: string;
|
|
62
|
+
rmail: string;
|
|
63
|
+
preferredComm: PrefferedCommunicationType;
|
|
64
|
+
};
|
|
65
|
+
operator: {
|
|
66
|
+
title: string;
|
|
67
|
+
address: ApiAddressGet;
|
|
68
|
+
};
|
|
69
|
+
}
|
|
56
70
|
export interface ApiOpportunityGetList {
|
|
57
71
|
id: Id;
|
|
58
72
|
title: string;
|
|
@@ -61,7 +75,8 @@ export interface ApiOpportunityGetList {
|
|
|
61
75
|
}
|
|
62
76
|
export interface ApiOpportunityGet extends ApiOpportunityGetList {
|
|
63
77
|
languages: ApiLanguage[];
|
|
64
|
-
activities:
|
|
65
|
-
skills:
|
|
66
|
-
location:
|
|
78
|
+
activities: OptionById[];
|
|
79
|
+
skills: OptionById[];
|
|
80
|
+
location: OptionById[];
|
|
81
|
+
agent: ApiOpportunityAgent;
|
|
67
82
|
}
|
|
@@ -1,4 +1,11 @@
|
|
|
1
1
|
import { Address } from "./location";
|
|
2
|
+
export declare enum PrefferedCommunicationType {
|
|
3
|
+
CALLED = "called",
|
|
4
|
+
EMAIL_SENT = "email-sent",
|
|
5
|
+
BRIEFED = "briefed",
|
|
6
|
+
TRIED_CALL = "tried-call",
|
|
7
|
+
NOT_RESPONDING = "not-responding"
|
|
8
|
+
}
|
|
2
9
|
export interface ApiPersonGet {
|
|
3
10
|
id: number;
|
|
4
11
|
avatarUrl: string;
|
|
@@ -8,4 +15,5 @@ export interface ApiPersonGet {
|
|
|
8
15
|
phone: string;
|
|
9
16
|
email: string;
|
|
10
17
|
address: Address;
|
|
18
|
+
preferredComm?: PrefferedCommunicationType;
|
|
11
19
|
}
|
package/dist/types/api/person.js
CHANGED
|
@@ -1,2 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PrefferedCommunicationType = void 0;
|
|
4
|
+
var PrefferedCommunicationType;
|
|
5
|
+
(function (PrefferedCommunicationType) {
|
|
6
|
+
PrefferedCommunicationType["CALLED"] = "called";
|
|
7
|
+
PrefferedCommunicationType["EMAIL_SENT"] = "email-sent";
|
|
8
|
+
PrefferedCommunicationType["BRIEFED"] = "briefed";
|
|
9
|
+
PrefferedCommunicationType["TRIED_CALL"] = "tried-call";
|
|
10
|
+
PrefferedCommunicationType["NOT_RESPONDING"] = "not-responding";
|
|
11
|
+
})(PrefferedCommunicationType || (exports.PrefferedCommunicationType = PrefferedCommunicationType = {}));
|
|
@@ -3,7 +3,7 @@ import { OptionId } from "./common";
|
|
|
3
3
|
import { ApiLanguage } from "./language";
|
|
4
4
|
import { ApiOpportunityGetList, OpportunityVolunteerStatusType } from "./opportunity";
|
|
5
5
|
import { OptionItem } from "./option";
|
|
6
|
-
import { ApiPersonGet } from "./person";
|
|
6
|
+
import { ApiPersonGet, PrefferedCommunicationType } from "./person";
|
|
7
7
|
import { ApiAvailability, TimedText } from "./time";
|
|
8
8
|
export interface Volunteer {
|
|
9
9
|
origin_opportunity: number | undefined;
|
|
@@ -80,12 +80,8 @@ export declare enum VolunteerStateType {
|
|
|
80
80
|
TEMP_INACTIVE = "Temp inactive",
|
|
81
81
|
INACTIVE = "Inactive"
|
|
82
82
|
}
|
|
83
|
-
export declare
|
|
84
|
-
|
|
85
|
-
PENDING_MATCH = "pending-match",
|
|
86
|
-
MATCHED = "matched",
|
|
87
|
-
NEEDS_REMATCH = "needs-rematch"
|
|
88
|
-
}
|
|
83
|
+
export declare const VolunteerStateMatchType: typeof PrefferedCommunicationType;
|
|
84
|
+
export type VolunteerStateMatchType = PrefferedCommunicationType;
|
|
89
85
|
export declare enum VolunteerCommunicationType {
|
|
90
86
|
EMAIL = "email",
|
|
91
87
|
MOBILE_PHONE = "mobilePhone",
|
|
@@ -134,7 +130,7 @@ export interface ApiVolunteerGet {
|
|
|
134
130
|
}
|
|
135
131
|
export interface VolunteerPatchBodyData extends Partial<ApiVolunteerGet> {
|
|
136
132
|
}
|
|
137
|
-
export interface
|
|
133
|
+
export interface ApiVolunteerOpportunityGet {
|
|
138
134
|
id: number;
|
|
139
135
|
opportunityId: number;
|
|
140
136
|
volunteerId: number;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.VolunteerCommunicationType = exports.VolunteerStateMatchType = exports.VolunteerStateType = exports.VolunteerStateCGCType = exports.VolunteerStateTypeType = exports.VolunteerStateAppreciationType = exports.VolunteerStateCommunicationType = exports.VolunteerStateEngagementType = void 0;
|
|
4
|
+
const person_1 = require("./person");
|
|
4
5
|
var VolunteerStateEngagementType;
|
|
5
6
|
(function (VolunteerStateEngagementType) {
|
|
6
7
|
VolunteerStateEngagementType["NEW"] = "new";
|
|
@@ -48,13 +49,7 @@ var VolunteerStateType;
|
|
|
48
49
|
VolunteerStateType["TEMP_INACTIVE"] = "Temp inactive";
|
|
49
50
|
VolunteerStateType["INACTIVE"] = "Inactive";
|
|
50
51
|
})(VolunteerStateType || (exports.VolunteerStateType = VolunteerStateType = {}));
|
|
51
|
-
|
|
52
|
-
(function (VolunteerStateMatchType) {
|
|
53
|
-
VolunteerStateMatchType["NO_MATCHES"] = "no-matches";
|
|
54
|
-
VolunteerStateMatchType["PENDING_MATCH"] = "pending-match";
|
|
55
|
-
VolunteerStateMatchType["MATCHED"] = "matched";
|
|
56
|
-
VolunteerStateMatchType["NEEDS_REMATCH"] = "needs-rematch";
|
|
57
|
-
})(VolunteerStateMatchType || (exports.VolunteerStateMatchType = VolunteerStateMatchType = {}));
|
|
52
|
+
exports.VolunteerStateMatchType = person_1.PrefferedCommunicationType;
|
|
58
53
|
var VolunteerCommunicationType;
|
|
59
54
|
(function (VolunteerCommunicationType) {
|
|
60
55
|
VolunteerCommunicationType["EMAIL"] = "email";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type PartialBy<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
|