Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[factory]: Add new talentprotocoltest group #2199

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions group-generators/generators/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -718,6 +718,7 @@ import talentProtocolTest from "./talent-protocol-test";
import talentlayer from "./talentlayer";
import talentofthemonthDesignMarch from "./talentofthemonth-design-march";
import tally from './tally';
import talentprotocoltest from "./talentprotocoltest";
import tallyHoGithubStargazers from "./tally-ho-github-stargazers";
import tarozzy from "./tarozzy";
import tayaFans from "./taya-fans";
Expand Down Expand Up @@ -1588,6 +1589,7 @@ export const groupGenerators: GroupGeneratorsLibrary = {
"talent-protocol-test": talentProtocolTest,
"talentlayer": talentlayer,
"talentofthemonth-design-march": talentofthemonthDesignMarch,
"talentprotocoltest": talentprotocoltest,
"tally": tally,
"tally-ho-github-stargazers": tallyHoGithubStargazers,
"tarozzy": tarozzy,
Expand Down
38 changes: 38 additions & 0 deletions group-generators/generators/talentprotocoltest/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@

import { dataProviders } from "@group-generators/helpers/data-providers";
import { Tags, ValueType, GroupWithData } from "topics/group";
import {
GenerationContext,
GenerationFrequency,
GroupGenerator,
} from "topics/group-generator";

// Generated from factory.sismo.io

const generator: GroupGenerator = {

generationFrequency: GenerationFrequency.Once,

generate: async (context: GenerationContext): Promise<GroupWithData[]> => {

const restProvider = new dataProviders.RestProvider();

const restProviderData0 = await restProvider.getAccountsFromAPI({
url: "https://api.talentprotocol.com/api/v1/talents/"
});

return [
{
name: "talentprotocoltest",
timestamp: context.timestamp,
description: "List of Talents",
specs: "List of talents",
data: restProviderData0,
valueType: ValueType.Score,
tags: [Tags.Factory],
},
];
},
};

export default generator;