Security News
Opengrep Emerges as Open Source Alternative Amid Semgrep Licensing Controversy
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
@poap-xyz/attributes
Advanced tools
Package to interact with POAP Attributes
npm install @poap-xyz/attributes @poap-xyz/utils @poap-xyz/providers axios form-data
yarn add @poap-xyz/attributes @poap-xyz/utils @poap-xyz/providers axios form-data
import { AttributesClient, FetchAttributesInput } from '@poap-xyz/attributes';
import { RegistryApiProvider, CompassProvider } from '@poap-xyz/providers';
const registryApiProvider = new RegistryApiProvider();
const compassProvider = new CompassProvider();
const attributesClient = new AttributesClient(registryApiProvider, compassProvider);
// Create a single attribute
const attribute = await attributesClient.create({
// Input data for creating the attribute
});
// Create multiple attributes
const attributes = await attributesClient.createBulk({
// Input data for creating the attributes
});
// Fetch a paginated list of attributes filtered by key and value, and sorted by order
const input: FetchAttributesInput = {
limit: 10,
offset: 0,
order: 'asc',
key: 'someKey',
value: 'someValue',
};
const result = await attributesClient.fetch(input);
A client for creating and fetching attributes.
AttributesClient(RegistryApiProvider, CompassProvider)
Creates a new AttributesClient instance.
RegistryApiProvider
(required): The registry API provider to use for creating attributes.CompassProvider
(required): The Compass provider to use for fetching attributes.create(input)
Creates a single attribute.
input
(required): The input data for creating the attribute.A Promise that resolves with the created attribute.
createBulk(input)
Creates multiple attributes.
input
(required): The input data for creating the attributes.A Promise that resolves with an array of the created attributes.
fetch(input)
Fetches a paginated list of attributes filtered by key and value, and sorted by order.
input
(required): An object containing the input parameters.
limit
(required): The maximum number of attributes to retrieve per page.offset
(required): The offset to start retrieving attributes from.order
(required): The attribute order to use. Can be "asc" or "desc".key
(optional): The key to filter the attributes by.value
(optional): The value to filter the attributes by.A promise that resolves to a paginated result of attributes.
A class representing an attribute.
Attribute({id, dropId, key, value, timestamp, tokenId})
Creates a new Attribute instance.
id
(required): The attribute ID.dropId
(optional): The drop ID associated with the attribute.key
(required): The attribute key.value
(required): The attribute value.timestamp
(required): The timestamp of the attribute.tokenId
(optional): The token ID associated with the attribute.For more detailed documentation, please visit this link.
For example scripts and usage, please check the examples.
We welcome contributions! Please see the CONTRIBUTING.md
file for guidelines.
@poap-xyz/attributes is released under the MIT License.
FAQs
Registry module for the poap.js library
The npm package @poap-xyz/attributes receives a total of 0 weekly downloads. As such, @poap-xyz/attributes popularity was classified as not popular.
We found that @poap-xyz/attributes demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Opengrep forks Semgrep to preserve open source SAST in response to controversial licensing changes.
Security News
Critics call the Node.js EOL CVE a misuse of the system, sparking debate over CVE standards and the growing noise in vulnerability databases.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.