@vansite/ts-sharetribe-flex-sdk
Version:
This is a TypeScript SDK for Sharetribe Flex API. It reduces the complexity of the API and provides a more user-friendly interface.
31 lines (30 loc) • 990 B
TypeScript
/**
* @fileoverview Client for fetching marketplace configuration in the Sharetribe Integration API.
*
* Use this to retrieve metadata about the marketplace (name, description, currency, etc.).
*
* @see https://www.sharetribe.com/api-reference/integration.html#marketplace
*/
import type { AxiosResponse } from "axios";
import IntegrationApi from "./index";
import { MarketplaceResponse } from "../../types";
/**
* Marketplace API client
*/
declare class Marketplace {
private readonly axios;
private readonly endpoint;
private readonly headers;
constructor(api: IntegrationApi);
/**
* Fetch current marketplace configuration
*
* @returns {Promise<AxiosResponse<MarketplaceResponse<"show">>>}
*
* @example
* const { data } = await sdk.marketplace.show();
* console.log(data.attributes.name); // → "My Awesome Marketplace"
*/
show(): Promise<AxiosResponse<MarketplaceResponse<"show">>>;
}
export default Marketplace;