@wefunder/sdk 0.1.0-beta.6 → 0.1.0-beta.8
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/README.md +14 -0
- package/dist/index.cjs +36 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1074 -168
- package/dist/index.d.ts +1074 -168
- package/dist/index.js +36 -2
- package/dist/index.js.map +1 -1
- package/examples_manifest.json +22 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1148,8 +1148,10 @@ __export(sdk_gen_exports, {
|
|
|
1148
1148
|
getCurrentUser: () => getCurrentUser,
|
|
1149
1149
|
getIntent: () => getIntent,
|
|
1150
1150
|
getOffering: () => getOffering,
|
|
1151
|
+
getPortfolio: () => getPortfolio,
|
|
1151
1152
|
getSyndicate: () => getSyndicate,
|
|
1152
1153
|
getSyndicateDeal: () => getSyndicateDeal,
|
|
1154
|
+
getSyndicatePortfolio: () => getSyndicatePortfolio,
|
|
1153
1155
|
getSyndicateStatistics: () => getSyndicateStatistics,
|
|
1154
1156
|
getWebhookSubscription: () => getWebhookSubscription,
|
|
1155
1157
|
hideSyndicateMember: () => hideSyndicateMember,
|
|
@@ -1163,10 +1165,12 @@ __export(sdk_gen_exports, {
|
|
|
1163
1165
|
listInvestments: () => listInvestments,
|
|
1164
1166
|
listOfferings: () => listOfferings,
|
|
1165
1167
|
listPartnerInvites: () => listPartnerInvites,
|
|
1168
|
+
listPortfolioPositions: () => listPortfolioPositions,
|
|
1166
1169
|
listSyndicateDealInvestors: () => listSyndicateDealInvestors,
|
|
1167
1170
|
listSyndicateDeals: () => listSyndicateDeals,
|
|
1168
1171
|
listSyndicateMemberInvestments: () => listSyndicateMemberInvestments,
|
|
1169
1172
|
listSyndicateMembers: () => listSyndicateMembers,
|
|
1173
|
+
listSyndicatePortfolioPositions: () => listSyndicatePortfolioPositions,
|
|
1170
1174
|
listSyndicates: () => listSyndicates,
|
|
1171
1175
|
listWebhookSubscriptions: () => listWebhookSubscriptions,
|
|
1172
1176
|
promoteSyndicateMember: () => promoteSyndicateMember,
|
|
@@ -1208,6 +1212,16 @@ var listInvestments = (options) => (options?.client ?? client).get({
|
|
|
1208
1212
|
url: "/investments",
|
|
1209
1213
|
...options
|
|
1210
1214
|
});
|
|
1215
|
+
var getPortfolio = (options) => (options?.client ?? client).get({
|
|
1216
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1217
|
+
url: "/portfolio",
|
|
1218
|
+
...options
|
|
1219
|
+
});
|
|
1220
|
+
var listPortfolioPositions = (options) => (options?.client ?? client).get({
|
|
1221
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1222
|
+
url: "/portfolio/positions",
|
|
1223
|
+
...options
|
|
1224
|
+
});
|
|
1211
1225
|
var listCampaigns = (options) => (options?.client ?? client).get({
|
|
1212
1226
|
security: [{ scheme: "bearer", type: "http" }],
|
|
1213
1227
|
url: "/campaigns",
|
|
@@ -1329,6 +1343,16 @@ var getSyndicateStatistics = (options) => (options.client ?? client).get({
|
|
|
1329
1343
|
url: "/syndicates/{syndicate_id}/statistics",
|
|
1330
1344
|
...options
|
|
1331
1345
|
});
|
|
1346
|
+
var getSyndicatePortfolio = (options) => (options.client ?? client).get({
|
|
1347
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1348
|
+
url: "/syndicates/{syndicate_id}/portfolio",
|
|
1349
|
+
...options
|
|
1350
|
+
});
|
|
1351
|
+
var listSyndicatePortfolioPositions = (options) => (options.client ?? client).get({
|
|
1352
|
+
security: [{ scheme: "bearer", type: "http" }],
|
|
1353
|
+
url: "/syndicates/{syndicate_id}/portfolio/positions",
|
|
1354
|
+
...options
|
|
1355
|
+
});
|
|
1332
1356
|
var closeSyndicateDeal = (options) => (options.client ?? client).post({
|
|
1333
1357
|
security: [{ scheme: "bearer", type: "http" }],
|
|
1334
1358
|
url: "/syndicates/{syndicate_id}/deals/{fundraise_id}/close",
|
|
@@ -1605,6 +1629,16 @@ var Wefunder = class _Wefunder {
|
|
|
1605
1629
|
all: () => paginate((cursor) => this.investments.list({ cursor })),
|
|
1606
1630
|
collect: () => collect((cursor) => this.investments.list({ cursor }))
|
|
1607
1631
|
};
|
|
1632
|
+
portfolio = {
|
|
1633
|
+
get: (query) => this.#unwrapData(getPortfolio({ client: this.#client, query })),
|
|
1634
|
+
positions: {
|
|
1635
|
+
list: this.#page(
|
|
1636
|
+
listPortfolioPositions
|
|
1637
|
+
),
|
|
1638
|
+
all: (query) => paginate((cursor) => this.portfolio.positions.list({ ...query, cursor })),
|
|
1639
|
+
collect: (query) => collect((cursor) => this.portfolio.positions.list({ ...query, cursor }))
|
|
1640
|
+
}
|
|
1641
|
+
};
|
|
1608
1642
|
campaigns = {
|
|
1609
1643
|
list: this.#page(listCampaigns),
|
|
1610
1644
|
all: () => paginate((cursor) => this.campaigns.list({ cursor })),
|
|
@@ -1612,12 +1646,12 @@ var Wefunder = class _Wefunder {
|
|
|
1612
1646
|
};
|
|
1613
1647
|
syndicates = {
|
|
1614
1648
|
list: this.#page(listSyndicates),
|
|
1615
|
-
all: () => paginate((cursor) => this.syndicates.list({ cursor })),
|
|
1649
|
+
all: (query) => paginate((cursor) => this.syndicates.list({ ...query, cursor })),
|
|
1616
1650
|
get: (id) => this.#unwrapData(getSyndicate({ client: this.#client, path: { id } }))
|
|
1617
1651
|
};
|
|
1618
1652
|
intents = {
|
|
1619
1653
|
list: this.#page(listIntents),
|
|
1620
|
-
all: () => paginate((cursor) => this.intents.list({ cursor })),
|
|
1654
|
+
all: (query) => paginate((cursor) => this.intents.list({ ...query, cursor })),
|
|
1621
1655
|
get: (id) => this.#unwrapData(getIntent({ client: this.#client, path: { id } }))
|
|
1622
1656
|
};
|
|
1623
1657
|
attribution = {
|