npm.io
2.2.0 • Published 2 weeks ago

pinterest-sdk

Licence
MIT
Version
2.2.0
Deps
2
Size
10.4 MB
Vulns
0
Weekly
0
Stars
4

pinterest-sdk

PinterestSdk - JavaScript client for pinterest-sdk Pinterest's REST API This SDK is automatically generated by the OpenAPI Generator project:

  • API version: 5.28.0
  • Package version: 2.2.0
  • Generator version: 7.26.0
  • Build package: org.openapitools.codegen.languages.JavascriptClientCodegen For more information, please visit https://github.com/oapicf/pinterest-sdk

Installation

For Node.js

npm

To publish the library as a npm, please follow the procedure in "Publishing npm packages".

Then install it via:

npm install pinterest-sdk --save

Finally, you need to build the module:

npm run build
Local development

To use the library locally without publishing to a remote npm registry, first install the dependencies by changing into the directory containing package.json (and this README). Let's call this JAVASCRIPT_CLIENT_DIR. Then run:

npm install

Next, link it globally in npm with the following, also from JAVASCRIPT_CLIENT_DIR:

npm link

To use the link you just defined in your project, switch to the directory you want to use your pinterest-sdk from, and run:

npm link /path/to/<JAVASCRIPT_CLIENT_DIR>

Finally, you need to build the module:

npm run build
git

If the library is hosted at a git repository, e.g.https://github.com/oapicf/pinterest-sdk then install it via:

    npm install oapicf/pinterest-sdk --save
For browser

The library also works in the browser environment via npm and browserify. After following the above steps with Node.js and installing browserify with npm install -g browserify, perform the following (assuming main.js is your entry file):

browserify main.js > bundle.js

Then include bundle.js in the HTML pages.

Webpack Configuration

Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:

module: {
  rules: [
    {
      parser: {
        amd: false
      }
    }
  ]
}

Getting Started

Please follow the installation instruction and execute the following JS code:

var PinterestSdk = require('pinterest-sdk');

var defaultClient = PinterestSdk.ApiClient.instance;
// Configure OAuth2 access token for authorization: pinterest_oauth2
var pinterest_oauth2 = defaultClient.authentications['pinterest_oauth2'];
pinterest_oauth2.accessToken = "YOUR ACCESS TOKEN"
// Configure OAuth2 access token for authorization: client_credentials
var client_credentials = defaultClient.authentications['client_credentials'];
client_credentials.accessToken = "YOUR ACCESS TOKEN"

var api = new PinterestSdk.AdAccountsApi()
var startDate = new Date("2013-10-20"); // {Date} Metric report start date (UTC). Format: YYYY-MM-DD. Cannot be more than 90 days back from today.
var endDate = new Date("2013-10-20"); // {Date} Metric report end date (UTC). Format: YYYY-MM-DD. Cannot be more than 90 days past start_date.
var columns = [new PinterestSdk.ReportingColumnSync()]; // {[ReportingColumnSync]} Columns to retrieve, encoded as a comma-separated string. **NOTE**: Any metrics defined as MICRO_DOLLARS returns a value based on the advertiser profile's currency field. For USD, ($1/1,000,000, or $0.000001 - one one-ten-thousandth of a cent). it's microdollars. Otherwise, it's in microunits of the advertiser's currency.  For example, if the advertiser's currency is GBP (British pound sterling), all MICRO_DOLLARS fields will be in GBP microunits (1/1,000,000 British pound).  If a column has no value, it may not be returned.
var granularity = new PinterestSdk.Granularity(); // {Granularity}   TOTAL - metrics are aggregated over the specified date range.    DAY - metrics are broken down daily.    HOUR - metrics are broken down hourly.    WEEK - metrics are broken down weekly.    MONTH - metrics are broken down monthly
var adAccountId = "adAccountId_example"; // {String} Unique identifier of an ad account.
var opts = {
  'clickWindowDays': 30, // {Number} Number of days to use as the conversion attribution window for a pin click action. Applies to Pinterest Tag conversion metrics. Prior conversion tags use their defined attribution windows. If not specified, defaults to `30` days.
  'engagementWindowDays': 30, // {Number} Number of days to use as the conversion attribution window for an engagement action. Engagements include saves, closeups, link clicks, and carousel card swipes. Applies to Pinterest Tag conversion metrics. Prior conversion tags use their defined attribution windows. If not specified, defaults to `30` days. **Note:** This parameter no longer returns new data. However, you can still access historic data through **Sept 30, 2027**.
  'viewWindowDays': 1, // {Number} Number of days to use as the conversion attribution window for a view action. Applies to Pinterest Tag conversion metrics. Prior conversion tags use their defined attribution windows. If not specified, defaults to `1` day.
  'conversionReportTime': "'TIME_OF_AD_ACTION'", // {String} The date by which the conversion metrics returned from this endpoint will be reported. There are two dates associated with a conversion event: the date that the user interacted with the ad, and the date that the user completed a conversion event.
  'reportingTimezone': new PinterestSdk.ReportingTimeZone() // {ReportingTimeZone} Specify the timezone to be applied for the reporting. This feature is currently in BETA and is not available to all users.
};
var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.adAccountAnalytics(startDate, endDate, columns, granularity, adAccountId, opts, callback);

Documentation for API Endpoints

All URIs are relative to https://api.pinterest.com/v5

Class Method HTTP request Description
PinterestSdk.AdAccountsApi adAccountAnalytics GET /ad_accounts/{ad_account_id}/analytics Get ad account analytics
PinterestSdk.AdAccountsApi adAccountTargetingAnalyticsGet GET /ad_accounts/{ad_account_id}/targeting_analytics Get targeting analytics for an ad account
PinterestSdk.AdAccountsApi adAccountsCreate POST /ad_accounts Create ad account
PinterestSdk.AdAccountsApi adAccountsGet GET /ad_accounts/{ad_account_id} Get ad account
PinterestSdk.AdAccountsApi adAccountsList GET /ad_accounts List ad accounts
PinterestSdk.AdAccountsApi analyticsCreateConversionProductReport POST /ad_accounts/{ad_account_id}/reports/brand_category_sku Create a request for a brand, category, SKU report
PinterestSdk.AdAccountsApi analyticsCreateMmmReport POST /ad_accounts/{ad_account_id}/mmm_reports Create a request for a Marketing Mix Modeling (MMM) report
PinterestSdk.AdAccountsApi analyticsCreateReport POST /ad_accounts/{ad_account_id}/reports Create async request for an account analytics report
PinterestSdk.AdAccountsApi analyticsCreateTemplateReport POST /ad_accounts/{ad_account_id}/templates/{template_id}/reports Create async request for an analytics report using a template
PinterestSdk.AdAccountsApi analyticsGetConversionProductReport GET /ad_accounts/{ad_account_id}/reports/brand_category_sku Get advertiser brand, category, SKU report
PinterestSdk.AdAccountsApi analyticsGetMmmReport GET /ad_accounts/{ad_account_id}/mmm_reports Get advertiser Marketing Mix Modeling (MMM) report.
PinterestSdk.AdAccountsApi analyticsGetReport GET /ad_accounts/{ad_account_id}/reports Get the account analytics report created by the async call
PinterestSdk.AdAccountsApi sandboxDelete DELETE /ad_accounts/{ad_account_id}/sandbox Delete ads data for ad account in API Sandbox
PinterestSdk.AdAccountsApi templatesList GET /ad_accounts/{ad_account_id}/templates List templates
PinterestSdk.AdGroupsApi adGroupsAnalytics GET /ad_accounts/{ad_account_id}/ad_groups/analytics Get ad group analytics
PinterestSdk.AdGroupsApi adGroupsAudienceSizing POST /ad_accounts/{ad_account_id}/ad_groups/audience_sizing Get audience sizing
PinterestSdk.AdGroupsApi adGroupsBidFloorGet POST /ad_accounts/{ad_account_id}/bid_floor Get bid floors
PinterestSdk.AdGroupsApi adGroupsCreate POST /ad_accounts/{ad_account_id}/ad_groups Create ad groups
PinterestSdk.AdGroupsApi adGroupsDynamicTitlesDownloadCsv GET /ad_accounts/{ad_account_id}/ad_groups/{ad_group_id}/dynamic_titles/csv Get dynamic titles CSV download URL
PinterestSdk.AdGroupsApi adGroupsDynamicTitlesGetStatus GET /ad_accounts/{ad_account_id}/ad_groups/{ad_group_id}/dynamic_titles/status Get dynamic titles status
PinterestSdk.AdGroupsApi adGroupsDynamicTitlesGetUploadUrl GET /ad_accounts/{ad_account_id}/ad_groups/{ad_group_id}/dynamic_titles/uploads Get dynamic titles upload URL
PinterestSdk.AdGroupsApi adGroupsDynamicTitlesProcessCsv POST /ad_accounts/{ad_account_id}/ad_groups/{ad_group_id}/dynamic_titles Process dynamic titles CSV
PinterestSdk.AdGroupsApi adGroupsGet GET /ad_accounts/{ad_account_id}/ad_groups/{ad_group_id} Get ad group
PinterestSdk.AdGroupsApi adGroupsList GET /ad_accounts/{ad_account_id}/ad_groups List ad groups
PinterestSdk.AdGroupsApi adGroupsTargetingAnalyticsGet GET /ad_accounts/{ad_account_id}/ad_groups/targeting_analytics Get targeting analytics for ad groups
PinterestSdk.AdGroupsApi adGroupsUpdate PATCH /ad_accounts/{ad_account_id}/ad_groups Update ad groups
PinterestSdk.AdGroupsApi getAdGroupsByPromotionIdsList GET /ad_accounts/{ad_account_id}/promotion_applied_entities List of ad groups using promotions IDs.
PinterestSdk.AdsApi adPreviewsCreate POST /ad_accounts/{ad_account_id}/ad_previews Create ad preview with pin or image
PinterestSdk.AdsApi adTargetingAnalyticsGet GET /ad_accounts/{ad_account_id}/ads/targeting_analytics Get targeting analytics for ads
PinterestSdk.AdsApi adsAnalytics GET /ad_accounts/{ad_account_id}/ads/analytics Get ad analytics
PinterestSdk.AdsApi adsCreate POST /ad_accounts/{ad_account_id}/ads Create ads
PinterestSdk.AdsApi adsGet GET /ad_accounts/{ad_account_id}/ads/{ad_id} Get ad
PinterestSdk.AdsApi adsList GET /ad_accounts/{ad_account_id}/ads List ads
PinterestSdk.AdsApi adsUpdate PATCH /ad_accounts/{ad_account_id}/ads Update ads
PinterestSdk.AdsApi campaignAdPreviewCreate POST /ad_accounts/{ad_account_id}/campaign_ad_preview Create ad preview records for one or more ad groups
PinterestSdk.AdsApi campaignAdPreviewDelete DELETE /ad_accounts/{ad_account_id}/campaign_ad_preview Delete ad preview records for one or more ad groups
PinterestSdk.AdsApi campaignAdPreviewRead GET /ad_accounts/{ad_account_id}/campaign_ad_preview Fetch ad preview records for one or more ad groups
PinterestSdk.AdvancedAuctionApi advancedAuctionItemsGetPost POST /advanced_auction/items/get Get item bid options (POST)
PinterestSdk.AdvancedAuctionApi advancedAuctionItemsSubmitPost POST /advanced_auction/items/submit Operate on item level bid options
PinterestSdk.AudienceInsightsApi audienceInsightsGet GET /ad_accounts/{ad_account_id}/audience_insights Get audience insights
PinterestSdk.AudienceInsightsApi audienceInsightsScopeAndTypeGet GET /ad_accounts/{ad_account_id}/insights/audiences Get audience insights scope and type
PinterestSdk.AudienceSharingApi adAccountsAudiencesSharedAccountsList GET /ad_accounts/{ad_account_id}/audiences/shared/accounts List accounts with access to an audience owned by an ad account
PinterestSdk.AudienceSharingApi businessAccountAudiencesSharedAccountsList GET /businesses/{business_id}/audiences/shared/accounts List accounts with access to an audience owned by a business
PinterestSdk.AudienceSharingApi sharedAudiencesForBusinessList GET /businesses/{business_id}/audiences List received audiences for a business
PinterestSdk.AudienceSharingApi updateAdAccountToAdAccountSharedAudience PATCH /ad_accounts/{ad_account_id}/audiences/ad_accounts/shared Update audience sharing between ad accounts
PinterestSdk.AudienceSharingApi updateAdAccountToBusinessSharedAudience PATCH /ad_accounts/{ad_account_id}/audiences/businesses/shared Update audience sharing from an ad account to businesses
PinterestSdk.AudienceSharingApi updateBusinessToAdAccountSharedAudience PATCH /businesses/{business_id}/audiences/ad_accounts/shared Update audience sharing from a business to ad accounts
PinterestSdk.AudienceSharingApi updateBusinessToBusinessSharedAudience PATCH /businesses/{business_id}/audiences/businesses/shared Update audience sharing between businesses
PinterestSdk.AudiencesApi audiencesCreate POST /ad_accounts/{ad_account_id}/audiences Create audience
PinterestSdk.AudiencesApi audiencesGet GET /ad_accounts/{ad_account_id}/audiences/{audience_id} Get audience
PinterestSdk.AudiencesApi audiencesList GET /ad_accounts/{ad_account_id}/audiences List audiences
PinterestSdk.AudiencesApi audiencesUpdate PATCH /ad_accounts/{ad_account_id}/audiences/{audience_id} Update audience
PinterestSdk.BillingApi adsCreditRedeem POST /ad_accounts/{ad_account_id}/ads_credit/redeem Redeem ad credits
PinterestSdk.BillingApi adsCreditsDiscountsGet GET /ad_accounts/{ad_account_id}/ads_credit/discounts Get ads credit discounts
PinterestSdk.BillingApi billingInvoiceDownloadGet GET /ad_accounts/{ad_account_id}/billing_invoice/{billing_invoice_id}/download Get download url for a billing invoice
PinterestSdk.BillingApi billingInvoicesGet GET /ad_accounts/{ad_account_id}/billing_invoices Get billing invoices
PinterestSdk.BillingApi billingProfilesGet GET /ad_accounts/{ad_account_id}/billing_profiles Get billing profiles
PinterestSdk.BillingApi ssioAccountsGet GET /ad_accounts/{ad_account_id}/ssio/accounts Get Salesforce account details including bill-to information.
PinterestSdk.BillingApi ssioInsertionOrderCreate POST /ad_accounts/{ad_account_id}/ssio/insertion_orders Create insertion order through SSIO.
PinterestSdk.BillingApi ssioInsertionOrderEdit PATCH /ad_accounts/{ad_account_id}/ssio/insertion_orders Edit insertion order through SSIO.
PinterestSdk.BillingApi ssioInsertionOrdersStatusGetByAdAccount GET /ad_accounts/{ad_account_id}/ssio/insertion_orders/status Get insertion order status by ad account id.
PinterestSdk.BillingApi ssioInsertionOrdersStatusGetByPinOrderId GET /ad_accounts/{ad_account_id}/ssio/insertion_orders/{pin_order_id}/status Get insertion order status by pin order id.
PinterestSdk.BillingApi ssioOrderLinesGetByAdAccount GET /ad_accounts/{ad_account_id}/ssio/order_lines Get Salesforce order lines by ad account id.
PinterestSdk.BoardsApi boardSectionsCreate POST /boards/{board_id}/sections Create board section
PinterestSdk.BoardsApi boardSectionsDelete DELETE /boards/{board_id}/sections/{section_id} Delete board section
PinterestSdk.BoardsApi boardSectionsList GET /boards/{board_id}/sections List board sections
PinterestSdk.BoardsApi boardSectionsListPins GET /boards/{board_id}/sections/{section_id}/pins List Pins on board section
PinterestSdk.BoardsApi boardSectionsUpdate PATCH /boards/{board_id}/sections/{section_id} Update board section
PinterestSdk.BoardsApi boardsCreate POST /boards Create board
PinterestSdk.BoardsApi boardsDelete DELETE /boards/{board_id} Delete board
PinterestSdk.BoardsApi boardsGet GET /boards/{board_id} Get board
PinterestSdk.BoardsApi boardsList GET /boards List boards
PinterestSdk.BoardsApi boardsListPins GET /boards/{board_id}/pins List Pins on board
PinterestSdk.BoardsApi boardsUpdate PATCH /boards/{board_id} Update board
PinterestSdk.BulkApi bulkDownloadCreate POST /ad_accounts/{ad_account_id}/bulk/download Get advertiser entities in bulk
PinterestSdk.BulkApi bulkRequestGet GET /ad_accounts/{ad_account_id}/bulk/{bulk_request_id} Download advertiser entities in bulk
PinterestSdk.BulkApi bulkUpsertCreate POST /ad_accounts/{ad_account_id}/bulk/upsert Create/update ad entities in bulk
PinterestSdk.BusinessAccessAssetsApi assetGroupCreate POST /businesses/{business_id}/asset_groups Create a new asset group.
PinterestSdk.BusinessAccessAssetsApi assetGroupDelete DELETE /businesses/{business_id}/asset_groups Delete asset groups.
PinterestSdk.BusinessAccessAssetsApi assetGroupUpdate PATCH /businesses/{business_id}/asset_groups Update asset groups.
PinterestSdk.BusinessAccessAssetsApi businessAssetMembersGet GET /businesses/{business_id}/assets/{asset_id}/members Get members with access to asset
PinterestSdk.BusinessAccessAssetsApi businessAssetPartnersGet GET /businesses/{business_id}/assets/{asset_id}/partners Get partners with access to asset
PinterestSdk.BusinessAccessAssetsApi businessAssetsGet GET /businesses/{business_id}/assets List business assets
PinterestSdk.BusinessAccessAssetsApi businessMemberAssetsGet GET /businesses/{business_id}/members/{member_id}/assets Get assets assigned to a member
PinterestSdk.BusinessAccessAssetsApi businessMembersAssetAccessDelete DELETE /businesses/{business_id}/members/assets/access Delete member access to asset
PinterestSdk.BusinessAccessAssetsApi businessMembersAssetAccessUpdate PATCH /businesses/{business_id}/members/assets/access Assign/Update member asset permissions
PinterestSdk.BusinessAccessAssetsApi businessPartnerAssetAccessGet GET /businesses/{business_id}/partners/{partner_id}/assets Get assets assigned to a partner or assets assigned by a partner
PinterestSdk.BusinessAccessAssetsApi deletePartnerAssetAccessHandlerImpl DELETE /businesses/{business_id}/partners/assets Delete partner access to asset
PinterestSdk.BusinessAccessAssetsApi updatePartnerAssetAccessHandlerImpl PATCH /businesses/{business_id}/partners/assets Assign/Update partner asset permissions
PinterestSdk.BusinessAccessInviteApi assetAccessRequestsCreate POST /businesses/{business_id}/requests/assets/access Create a request to access an existing partner's assets.
PinterestSdk.BusinessAccessInviteApi cancelInvitesOrRequests DELETE /businesses/{business_id}/invites Cancel invites/requests
PinterestSdk.BusinessAccessInviteApi createAssetInvites POST /businesses/{business_id}/invites/assets/access Update invite/request with an asset permission
PinterestSdk.BusinessAccessInviteApi createMembershipOrPartnershipInvites POST /businesses/{business_id}/invites Create invites or requests
PinterestSdk.BusinessAccessInviteApi getInvites GET /businesses/{business_id}/invites Get invites/requests
PinterestSdk.BusinessAccessInviteApi respondBusinessAccessInvites PATCH /businesses/invites Accept or decline an invite/request
PinterestSdk.BusinessAccessRelationshipsApi brandAccountsCreate POST /business_access/business_hierarchy/{business_hierarchy_id}/brand_accounts Create a Brand Account
PinterestSdk.BusinessAccessRelationshipsApi brandAccountsUpdate PATCH /business_access/business_hierarchy/{business_hierarchy_id}/brand_accounts/{brand_account_id} Update a Brand Account
PinterestSdk.BusinessAccessRelationshipsApi deleteBusinessMembership DELETE /businesses/{business_id}/members Terminate business memberships
PinterestSdk.BusinessAccessRelationshipsApi deleteBusinessPartners DELETE /businesses/{business_id}/partners Terminate business partnerships
PinterestSdk.BusinessAccessRelationshipsApi getBusinessEmployers GET /businesses/employers List business employers for user
PinterestSdk.BusinessAccessRelationshipsApi getBusinessMembers GET /businesses/{business_id}/members Get business members
PinterestSdk.BusinessAccessRelationshipsApi getBusinessPartners GET /businesses/{business_id}/partners Get business partners
PinterestSdk.BusinessAccessRelationshipsApi systemUserUpdate PATCH /businesses/{business_id}/system_users/{system_user_id} Update a system user information.
PinterestSdk.BusinessAccessRelationshipsApi updateBusinessMemberships PATCH /businesses/{business_id}/members Update member's business role
PinterestSdk.CampaignsApi adPinsAnalytics GET /ad_accounts/{ad_account_id}/pins/analytics Get pins analytics
PinterestSdk.CampaignsApi campaignTargetingAnalyticsGet GET /ad_accounts/{ad_account_id}/campaigns/targeting_analytics Get targeting analytics for campaigns
PinterestSdk.CampaignsApi campaignsAnalytics GET /ad_accounts/{ad_account_id}/campaigns/analytics Get campaign analytics
PinterestSdk.CampaignsApi campaignsCreate POST /ad_accounts/{ad_account_id}/campaigns Create campaigns
PinterestSdk.CampaignsApi campaignsGet GET /ad_accounts/{ad_account_id}/campaigns/{campaign_id} Get campaign
PinterestSdk.CampaignsApi campaignsList GET /ad_accounts/{ad_account_id}/campaigns List campaigns
PinterestSdk.CampaignsApi campaignsUpdate PATCH /ad_accounts/{ad_account_id}/campaigns Update campaigns
PinterestSdk.CampaignsApi getCampaignDeliveryEstimates POST /ad_accounts/{ad_account_id}/campaigns/delivery_estimates Get campaign delivery estimates
PinterestSdk.CatalogFeedsApi feedProcessingResultsList GET /catalogs/feeds/{feed_id}/processing_results List feed processing results
PinterestSdk.CatalogFeedsApi feedsCreate POST /catalogs/feeds Create feed
PinterestSdk.CatalogFeedsApi feedsDelete DELETE /catalogs/feeds/{feed_id} Delete feed
PinterestSdk.CatalogFeedsApi feedsGet GET /catalogs/feeds/{feed_id} Get feed
PinterestSdk.CatalogFeedsApi feedsIngest POST /catalogs/feeds/{feed_id}/ingest Ingest feed items
PinterestSdk.CatalogFeedsApi feedsList GET /catalogs/feeds List feeds
PinterestSdk.CatalogFeedsApi feedsUpdate PATCH /catalogs/feeds/{feed_id} Update feed
PinterestSdk.CatalogFeedsApi itemsIssuesList GET /catalogs/processing_results/{processing_result_id}/item_issues List item issues
PinterestSdk.CatalogItemsApi itemsBatchGet GET /catalogs/items/batch/{batch_id} Get item batch status
PinterestSdk.CatalogItemsApi itemsBatchPost POST /catalogs/items/batch Operate on item batch
PinterestSdk.CatalogItemsApi itemsPost POST /catalogs/items Get catalogs items (POST)
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupPinsList GET /catalogs/product_groups/{product_group_id}/products List products by product group
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsCreate POST /catalogs/product_groups Create product group
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsCreateMany POST /catalogs/product_groups/multiple Create product groups
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsDelete DELETE /catalogs/product_groups/{product_group_id} Delete product group
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsDeleteMany DELETE /catalogs/product_groups/multiple Delete product groups
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsGet GET /catalogs/product_groups/{product_group_id} Get product group
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsList GET /catalogs/product_groups List product groups
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsProductCountsGet GET /catalogs/product_groups/{product_group_id}/product_counts Get product counts
PinterestSdk.CatalogProductGroupsApi catalogsProductGroupsUpdate PATCH /catalogs/product_groups/{product_group_id} Update single product group
PinterestSdk.CatalogProductGroupsApi productsByProductGroupFilterList POST /catalogs/products/get_by_product_group_filters List products by filter
PinterestSdk.CatalogReportsApi reportsCreate POST /catalogs/reports Build catalogs report
PinterestSdk.CatalogReportsApi reportsGet GET /catalogs/reports Get catalogs report
PinterestSdk.CatalogReportsApi reportsStats GET /catalogs/reports/stats List report stats
PinterestSdk.CatalogSupplementalApi catalogsLocalInventoryItemsBatchOperate POST /catalogs/{catalog_id}/local_inventory_items/batch Operate on local inventory item batch
PinterestSdk.CatalogSupplementalApi catalogsLocalInventoryItemsPost POST /catalogs/{catalog_id}/local_inventory_items/query Get local inventory items (POST)
PinterestSdk.CatalogSupplementalApi catalogsLocalStoresCreate POST /catalogs/{catalog_id}/local_stores Create local stores
PinterestSdk.CatalogSupplementalApi catalogsLocalStoresDelete DELETE /catalogs/{catalog_id}/local_stores Delete local stores
PinterestSdk.CatalogSupplementalApi catalogsLocalStoresList GET /catalogs/{catalog_id}/local_stores List local stores
PinterestSdk.CatalogSupplementalApi catalogsLocalStoresUpdate PATCH /catalogs/{catalog_id}/local_stores Update local stores
PinterestSdk.CatalogSupplementalApi catalogsSupplementalItemsBatchGet GET /catalogs/{catalog_id}/supplemental_items/batch/{batch_id} Get supplemental items batch status
PinterestSdk.CatalogsApi catalogsAvailableFilterValues GET /catalogs/available_filter_values List available filter values
PinterestSdk.CatalogsApi catalogsCreate POST /catalogs Create catalog
PinterestSdk.CatalogsApi catalogsList GET /catalogs List catalogs
PinterestSdk.ConversionDeletionRequestsApi conversionDeletionRequestCreate POST /ad_accounts/{ad_account_id}/conversion_deletion_requests Create a conversion deletion request
PinterestSdk.ConversionDeletionRequestsApi conversionDeletionRequestDelete DELETE /ad_accounts/{ad_account_id}/conversion_deletion_requests/{request_id} Delete a conversion deletion request
PinterestSdk.ConversionDeletionRequestsApi conversionDeletionRequestGet GET /ad_accounts/{ad_account_id}/conversion_deletion_requests/{request_id} Get a single conversion deletion request
PinterestSdk.ConversionDeletionRequestsApi conversionDeletionRequestList GET /ad_accounts/{ad_account_id}/conversion_deletion_requests List conversion deletion requests
PinterestSdk.ConversionEqsApi conversionEqsList GET /ad_accounts/{ad_account_id}/conversion_eqs Get event quality score (EQS)
PinterestSdk.ConversionEventsApi eventsCreate POST /ad_accounts/{ad_account_id}/events Send conversions
PinterestSdk.ConversionTagsApi conversionTagsCreate POST /ad_accounts/{ad_account_id}/conversion_tags Create conversion tag
PinterestSdk.ConversionTagsApi conversionTagsGet GET /ad_accounts/{ad_account_id}/conversion_tags/{conversion_tag_id} Get conversion tag
PinterestSdk.ConversionTagsApi conversionTagsList GET /ad_accounts/{ad_account_id}/conversion_tags List conversion tags
PinterestSdk.ConversionTagsApi ocpmEligibleConversionTagsGet GET /ad_accounts/{ad_account_id}/conversion_tags/ocpm_eligible Get Ocpm eligible conversion tags
PinterestSdk.ConversionTagsApi pageVisitConversionTagsGet GET /ad_accounts/{ad_account_id}/conversion_tags/page_visit Get page visit conversion tags
PinterestSdk.ConversionsApi advertiserDefinedEventsCreate POST /ad_accounts/{ad_account_id}/advertiser_defined_events Create advertiser defined events
PinterestSdk.ConversionsApi advertiserDefinedEventsDelete DELETE /ad_accounts/{ad_account_id}/advertiser_defined_events Delete advertiser defined events
PinterestSdk.ConversionsApi advertiserDefinedEventsGet GET /ad_accounts/{ad_account_id}/advertiser_defined_events Get advertiser defined events
PinterestSdk.ConversionsApi advertiserDefinedEventsUpdate PATCH /ad_accounts/{ad_account_id}/advertiser_defined_events Update advertiser defined events
PinterestSdk.CustomerListUploadsApi customerListUploadsCreate POST /ad_accounts/{ad_account_id}/customer_lists/{customer_list_id}/uploads Create customer list upload
PinterestSdk.CustomerListUploadsApi customerListUploadsGet GET /ad_accounts/{ad_account_id}/customer_lists/{customer_list_id}/uploads/{customer_list_upload_id} Get customer list upload
PinterestSdk.CustomerListUploadsApi customerListUploadsRun POST /ad_accounts/{ad_account_id}/customer_lists/{customer_list_id}/uploads/{customer_list_upload_id}/run Run customer list upload
PinterestSdk.CustomerListsApi customerListsCreate POST /ad_accounts/{ad_account_id}/customer_lists Create customer lists
PinterestSdk.CustomerListsApi customerListsGet GET /ad_accounts/{ad_account_id}/customer_lists/{customer_list_id} Get customer list
PinterestSdk.CustomerListsApi customerListsList GET /ad_accounts/{ad_account_id}/customer_lists Get customer lists
PinterestSdk.CustomerListsApi customerListsUpdate PATCH /ad_accounts/{ad_account_id}/customer_lists/{customer_list_id} Update customer list
PinterestSdk.CustomerSegmentApi customerSegmentCreate POST /ad_accounts/{ad_account_id}/customer_segments Create customer segments
PinterestSdk.CustomerSegmentApi customerSegmentList GET /ad_accounts/{ad_account_id}/customer_segments List customer segments
PinterestSdk.CustomerSegmentApi customerSegmentUpdate PATCH /ad_accounts/{ad_account_id}/customer_segments Update customer segments
PinterestSdk.IntegrationsApi integrationsCommerceDel DELETE /integrations/commerce/{external_business_id} Delete commerce integration
PinterestSdk.IntegrationsApi integrationsCommerceGet GET /integrations/commerce/{external_business_id} Get commerce integration
PinterestSdk.IntegrationsApi integrationsCommercePatch PATCH /integrations/commerce/{external_business_id} Update commerce integration
PinterestSdk.IntegrationsApi integrationsCommercePost POST /integrations/commerce Create commerce integration
PinterestSdk.IntegrationsApi integrationsGetById GET /integrations/{id} Get integration metadata
PinterestSdk.IntegrationsApi integrationsGetList GET /integrations Get integration metadata list
PinterestSdk.IntegrationsApi integrationsLogsPost POST /integrations/logs Receives batched logs from integration applications.
PinterestSdk.KeywordsApi countryKeywordsMetricsGet GET /ad_accounts/{ad_account_id}/keywords/metrics Get country's keyword metrics
PinterestSdk.KeywordsApi keywordsCreate POST /ad_accounts/{ad_account_id}/keywords Create keywords
PinterestSdk.KeywordsApi keywordsGet GET /ad_accounts/{ad_account_id}/keywords Get keywords
PinterestSdk.KeywordsApi keywordsUpdate PATCH /ad_accounts/{ad_account_id}/keywords Update keywords
PinterestSdk.KeywordsApi trendingKeywordsList GET /trends/keywords/{region}/top/{trend_type} List trending keywords
PinterestSdk.LabelsApi labelsApply POST /ad_accounts/{ad_account_id}/labels/{label_id}/apply Apply label to entity
PinterestSdk.LabelsApi labelsCreate POST /ad_accounts/{ad_account_id}/labels Create labels
PinterestSdk.LabelsApi labelsList GET /ad_accounts/{ad_account_id}/labels List labels
PinterestSdk.LabelsApi labelsRemove POST /ad_accounts/{ad_account_id}/labels/{label_id}/remove Remove label from entities
PinterestSdk.LabelsApi labelsUpdate PATCH /ad_accounts/{ad_account_id}/labels Update labels
PinterestSdk.LeadAdsApi adAccountsSubscriptionsDelById DELETE /ad_accounts/{ad_account_id}/leads/subscriptions/{subscription_id} Delete lead ads subscription
PinterestSdk.LeadAdsApi adAccountsSubscriptionsGetById GET /ad_accounts/{ad_account_id}/leads/subscriptions/{subscription_id} Get lead ads subscription by ID
PinterestSdk.LeadAdsApi adAccountsSubscriptionsGetList GET /ad_accounts/{ad_account_id}/leads/subscriptions Get lead ads subscriptions
PinterestSdk.LeadAdsApi adAccountsSubscriptionsPost POST /ad_accounts/{ad_account_id}/leads/subscriptions Create lead ads subscription
PinterestSdk.LeadFormsApi leadFormGet GET /ad_accounts/{ad_account_id}/lead_forms/{lead_form_id} Get lead form by id
PinterestSdk.LeadFormsApi leadFormTestCreate POST /ad_accounts/{ad_account_id}/lead_forms/{lead_form_id}/test Create lead form test data
PinterestSdk.LeadFormsApi leadFormsCreate POST /ad_accounts/{ad_account_id}/lead_forms Create lead forms
PinterestSdk.LeadFormsApi leadFormsList GET /ad_accounts/{ad_account_id}/lead_forms List lead forms
PinterestSdk.LeadFormsApi leadFormsUpdate PATCH /ad_accounts/{ad_account_id}/lead_forms Update lead forms
PinterestSdk.LeadsExportApi leadsExportCreate POST /ad_accounts/{ad_account_id}/leads_export Create a request to export leads collected from a lead ad
PinterestSdk.LeadsExportApi leadsExportGet GET /ad_accounts/{ad_account_id}/leads_export/{leads_export_id} Get the lead export from the lead export create call
PinterestSdk.MediaApi mediaCreate POST /media Register media upload
PinterestSdk.MediaApi mediaGet GET /media/{media_id} Get media upload details
PinterestSdk.MediaApi mediaList GET /media List media uploads
PinterestSdk.MsotEventsApi msotEventsCreate POST /ad_accounts/{ad_account_id}/msot/events Send Measurement Source Of Truth (MSOT) attributed conversion events
PinterestSdk.NotificationApi notificationPost POST /notifications Receive notifications from external partners.
PinterestSdk.OauthApi oauthConversionToken POST /oauth/conversion_token Generate OAuth access token for conversion API
PinterestSdk.OauthApi oauthToken POST /oauth/token Generate OAuth access token
PinterestSdk.OauthApi tokenRevoke POST /oauth/token/revoke Revoke a token
PinterestSdk.OrderLinesApi orderLinesGet GET /ad_accounts/{ad_account_id}/order_lines/{order_line_id} Get order line
PinterestSdk.OrderLinesApi orderLinesList GET /ad_accounts/{ad_account_id}/order_lines Get order lines.
PinterestSdk.PinsApi multiPinsAnalytics GET /pins/analytics Get multiple Pin analytics
PinterestSdk.PinsApi pinsAnalytics GET /pins/{pin_id}/analytics Get Pin analytics
PinterestSdk.PinsApi pinsCreate POST /pins Create Pin
PinterestSdk.PinsApi pinsDelete DELETE /pins/{pin_id} Delete Pin
PinterestSdk.PinsApi pinsGet GET /pins/{pin_id} Get Pin
PinterestSdk.PinsApi pinsList GET /pins List Pins
PinterestSdk.PinsApi pinsSave POST /pins/{pin_id}/save Save Pin
PinterestSdk.PinsApi pinsUpdate PATCH /pins/{pin_id} Update Pin
PinterestSdk.ProductGroupPromotionsApi productGroupPromotionsCreate POST /ad_accounts/{ad_account_id}/product_group_promotions Create product group promotions
PinterestSdk.ProductGroupPromotionsApi productGroupPromotionsGet GET /ad_accounts/{ad_account_id}/product_group_promotions/{product_group_promotion_id} Get a product group promotion by id
PinterestSdk.ProductGroupPromotionsApi productGroupPromotionsList GET /ad_accounts/{ad_account_id}/product_group_promotions Get product group promotions
PinterestSdk.ProductGroupPromotionsApi productGroupPromotionsUpdate PATCH /ad_accounts/{ad_account_id}/product_group_promotions Update product group promotions
PinterestSdk.ProductGroupPromotionsApi productGroupsAnalytics GET /ad_accounts/{ad_account_id}/product_groups/analytics Get product group analytics
PinterestSdk.ProductTagsApi productTagsBulkAdd POST /pins/{pin_id}/product_tags Add product tags to pin
PinterestSdk.ProductTagsApi productTagsBulkDelete POST /pins/{pin_id}/product_tags/bulk-delete Delete product tags from pin
PinterestSdk.ProductTagsApi productTagsList GET /pins/{pin_id}/product_tags Get product tags for pin
PinterestSdk.PromotionsApi promotionsCreate POST /ad_accounts/{ad_account_id}/promotions Create promotions
PinterestSdk.PromotionsApi promotionsDelete DELETE /ad_accounts/{ad_account_id}/promotions/{promotion_id} Delete promotion by id
PinterestSdk.PromotionsApi promotionsGet GET /ad_accounts/{ad_account_id}/promotions/{promotion_id} Get promotion by id
PinterestSdk.PromotionsApi promotionsList GET /ad_accounts/{ad_account_id}/promotions Get promotions
PinterestSdk.PromotionsApi promotionsUpdate PATCH /ad_accounts/{ad_account_id}/promotions Update promotions
PinterestSdk.ResourcesApi adAccountCountriesGet GET /resources/ad_account_countries Get ad accounts countries
PinterestSdk.ResourcesApi deliveryMetricsGet GET /resources/delivery_metrics Get available metrics' definitions
PinterestSdk.ResourcesApi interestTargetingOptionsGet GET /resources/targeting/interests/{interest_id} Get interest details
PinterestSdk.ResourcesApi leadFormQuestionsGet GET /resources/lead_form_questions Get lead form questions
PinterestSdk.ResourcesApi metricsReadyStateGet GET /resources/metrics_ready_state Get metrics ready state
PinterestSdk.ResourcesApi targetingOptionsGet GET /resources/targeting/{targeting_type} Get targeting options
PinterestSdk.SchedulesApi schedulesCreate POST /ad_accounts/{ad_account_id}/schedules Create schedules
PinterestSdk.SchedulesApi schedulesList GET /ad_accounts/{ad_account_id}/schedules Get Schedules
PinterestSdk.SchedulesApi schedulesUpdate PATCH /ad_accounts/{ad_account_id}/schedules Update schedules
PinterestSdk.SearchApi searchPartnerPins GET /search/partner/pins Search pins by a given search term
PinterestSdk.SearchApi searchUserBoardsGet GET /search/boards Search user's boards
PinterestSdk.SearchApi searchUserPinsList GET /search/pins Search user's Pins
PinterestSdk.TargetingTemplateApi targetingTemplateCreate POST /ad_accounts/{ad_account_id}/targeting_templates Create targeting templates
PinterestSdk.TargetingTemplateApi targetingTemplateList GET /ad_accounts/{ad_account_id}/targeting_templates List targeting templates
PinterestSdk.TargetingTemplateApi targetingTemplateUpdate PATCH /ad_accounts/{ad_account_id}/targeting_templates Update targeting templates
PinterestSdk.TermsApi termsRelatedList GET /terms/related List related terms
PinterestSdk.TermsApi termsSuggestedList GET /terms/suggested List suggested terms
PinterestSdk.TermsOfServiceApi termsOfServiceGet GET /ad_accounts/{ad_account_id}/terms_of_service Get terms of service
PinterestSdk.TrendsApi trendsEditorialArticlesList GET /trends/editorial_articles Returns editorial articles for a given region
PinterestSdk.TrendsApi trendsFeaturedTopicsList GET /trends/topics/featured Get featured topics
PinterestSdk.TrendsApi trendsProductCategoriesDetailsList GET /trends/product_categories/details Get product category details
PinterestSdk.TrendsApi trendsProductCategoriesTrendingList GET /trends/product_categories/trending Get a list of growing Shopping Product Categories
PinterestSdk.UserAccountApi boardsUserFollowsList GET /user_account/following/boards List following boards
PinterestSdk.UserAccountApi followUserUpdate POST /user_account/following/{username} Follow user
PinterestSdk.UserAccountApi followersList GET /user_account/followers List followers
PinterestSdk.UserAccountApi linkedBusinessAccountsGet GET /user_account/businesses List linked businesses
PinterestSdk.UserAccountApi unverifyWebsiteDelete DELETE /user_account/websites Unverify website
PinterestSdk.UserAccountApi userAccountAnalytics GET /user_account/analytics Get user account analytics
PinterestSdk.UserAccountApi userAccountAnalyticsTopPins GET /user_account/analytics/top_pins Get user account top pins analytics
PinterestSdk.UserAccountApi userAccountAnalyticsTopVideoPins GET /user_account/analytics/top_video_pins Get user account top video pins analytics
PinterestSdk.UserAccountApi userAccountFollowedInterests GET /users/{username}/interests/follow List following interests
PinterestSdk.UserAccountApi userAccountGet GET /user_account Get user account
PinterestSdk.UserAccountApi userFollowingGet GET /user_account/following List following
PinterestSdk.UserAccountApi userWebsitesGet GET /user_account/websites Get user websites
PinterestSdk.UserAccountApi verifyWebsiteUpdate POST /user_account/websites Verify website
PinterestSdk.UserAccountApi websiteVerificationGet GET /user_account/websites/verification Get user verification code for website claiming

Documentation for Models

Documentation for Authorization

Authentication schemes defined for the API:

pinterest_oauth2
  • Type: OAuth
  • Flow: accessCode
  • Authorization URL: https://www.pinterest.com/oauth/
  • Scopes:
    • ads See all of your advertising data, including ads, ad groups, campaigns etc.
    • ads Create, update, or delete ads, ad groups, campaigns etc.
    • billing See all of your billing data, billing profile, etc.
    • billing Create, update, or delete billing data, billing profiles, etc.
    • biz_access See business access data
    • biz_access Create, update, or delete business access data
    • boards See your public boards, including group boards you join
    • boards See your secret boards
    • boards Create, update, or delete your public boards
    • boards Create, update, or delete your secret boards
    • catalogs See all of your catalogs data
    • catalogs Create, update, or delete your catalogs data
    • msot Create measurement source of truth events
    • pins See your public Pins
    • pins See your secret Pins
    • pins Create, update, or delete your public Pins
    • pins Create, update, or delete your secret Pins
    • user_accounts See your user accounts and followers
    • user_accounts Update your user accounts and followers
client_credentials
  • Type: OAuth
  • Flow: application
  • Authorization URL:
  • Scopes:
    • ads See all of your advertising data, including ads, ad groups, campaigns etc.
    • ads Create, update, or delete ads, ad groups, campaigns etc.
    • billing See all of your billing data, billing profile, etc.
    • billing Create, update, or delete billing data, billing profiles, etc.
    • biz_access See business access data
    • biz_access Create, update, or delete business access data
    • boards See your public boards, including group boards you join
    • boards See your secret boards
    • boards Create, update, or delete your public boards
    • boards Create, update, or delete your secret boards
    • catalogs See all of your catalogs data
    • catalogs Create, update, or delete your catalogs data
    • msot Create measurement source of truth events
    • pins See your public Pins
    • pins See your secret Pins
    • pins Create, update, or delete your public Pins
    • pins Create, update, or delete your secret Pins
    • user_accounts See your user accounts and followers
    • user_accounts Update your user accounts and followers
conversion_token
  • Type: Bearer authentication
basic
  • Type: HTTP basic authentication