openapi: 3.0.3
info:
version: 5.13.0
title: Pinterest User_account API
description: This is the description of your API.
contact:
name: Pinterest, Inc.
url: https://developers.pinterest.com/
license:
name: MIT
url: https://spdx.org/licenses/MIT
termsOfService: https://developers.pinterest.com/terms/
servers:
- url: https://api.pinterest.com/v5
tags:
- name: User_account
paths:
/user_account/businesses:
get:
summary: List linked businesses
description: Get a list of your linked business accounts.
operationId: linked_business_accounts/get
security:
- pinterest_oauth2:
- user_accounts:read
x-ratelimit-category: org_read
x-sandbox: enabled
responses:
'200':
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/LinkedBusiness'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
description: Unexpected error
tags:
- User_account
/user_account/following/boards:
get:
summary: List following boards
description: Get a list of the boards a user follows. The request returns a board summary object array.
operationId: boards_user_follows/list
security:
- pinterest_oauth2:
- user_accounts:read
x-ratelimit-category: org_read
x-sandbox: enabled
parameters:
- $ref: '#/components/parameters/query_bookmark'
- $ref: '#/components/parameters/query_page_size'
- $ref: '#/components/parameters/query_explicit_following'
- $ref: '#/components/parameters/query_ad_account_id'
responses:
'200':
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/Paginated'
- type: object
properties:
items:
type: array
items:
$ref: '#/components/schemas/Board'
description: Success
'400':
description: Invalid user id
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
example:
code: 400
message: Invalid user id
default:
description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
tags:
- User_account
/user_account/websites:
post:
summary: Verify website
description: Verify a website as a signed-in user.
tags:
- User_account
operationId: verify_website/update
security:
- pinterest_oauth2:
- user_accounts:write
x-ratelimit-category: org_write
x-sandbox: disabled
requestBody:
description: Verify a website.
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UserWebsiteVerifyRequest'
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/UserWebsiteSummary'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
description: Unexpected error
get:
summary: Get user websites
description: Get user websites, claimed or not
tags:
- User_account
operationId: user_websites/get
security:
- pinterest_oauth2:
- user_accounts:read
parameters:
- $ref: '#/components/parameters/query_bookmark'
- $ref: '#/components/parameters/query_page_size'
responses:
'200':
description: Success
content:
application/json:
schema:
allOf:
- $ref: '#/components/schemas/Paginated'
- type: object
properties:
items:
type: array
items:
$ref: '#/components/schemas/UserWebsiteSummary'
'403':
description: Not authorized to access the user website list.
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
example:
code: 403
message: Not authorized to access the user website list.
default:
description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
x-ratelimit-category: org_read
x-sandbox: disabled
delete:
summary: Unverify website
description: Unverifu a website verified by the signed-in user.
tags:
- User_account
operationId: unverify_website/delete
security:
- pinterest_oauth2:
- user_accounts:write
x-ratelimit-category: org_write
x-sandbox: disabled
parameters:
- $ref: '#/components/parameters/query_website'
responses:
'204':
description: Successfully unverified website
'404':
description: Website not in user list.
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
example:
code: 404
message: Website not in user list.
default:
description: Unexpected error
content:
application/json:
schema:
$ref: '#/components/schemas/Error'
components:
schemas:
BoardOwner:
title: Board owner
type: object
properties:
username:
type: string
readOnly: true
UserWebsiteVerifyRequest:
title: User website verification request
description: User website verification request
type: object
properties:
website:
type: string
example: pintest-website-12345678.test/test_1
verification_method:
type: string
default: METATAG
enum:
- FILENAME
- METATAG
- DNSTXT
LinkedBusiness:
title: LinkedBusiness
type: object
properties:
username:
title: username
type: string
description: Username
example: username
image_small_url:
title: image_small_url
type: string
description: image_small_url
example: https://www.example.com/dj23454f53dfk2324.jpg
image_medium_url:
title: image_medium_url
type: string
description: image_medium_url
example: https://www.example.com/dj23454f53dfk2324.jpg
image_large_url:
title: image_large_url
type: string
description: image_large_url
example: https://www.example.com/dj23454f53dfk2324.jpg
image_xlarge_url:
title: image_xlarge_url
type: string
description: image_xlarge_url
example: https://www.example.com/dj23454f53dfk2324.jpg
UserWebsiteSummary:
title: UserWebsiteSummary
type: object
properties:
website:
title: website
type: string
description: Website with path or domain only
example: mysite.test
status:
title: status
type: string
description: Status of the verification process
example: success
verified_at:
title: verified_at
type: string
description: UTC timestamp when the verification happened - sometimes missing
example: '2022-12-14T21:03:01.602000'
Error:
title: Error
type: object
properties:
code:
type: integer
message:
type: string
required:
- code
- message
Board:
title: Board
description: Board
type: object
properties:
id:
type: string
readOnly: true
example: '549755885175'
created_at:
type: string
description: Date and time of board creation.
readOnly: true
format: date-time
example: '2020-01-01T20:10:40-00:00'
board_pins_modified_at:
type: string
description: Date and time of last board pins modified.
readOnly: true
format: date-time
example: '2020-01-01T20:10:40-00:00'
name:
type: string
example: Summer Recipes
description:
type: string
nullable: true
example: My favorite summer recipes
collaborator_count:
type: integer
description: Count of collaborators on the board.
minimum: 0
readOnly: true
example: 17
pin_count:
type: integer
description: Count of pins on the board.
minimum: 0
readOnly: true
example: 5
follower_count:
type: integer
description: Board follower count.
readOnly: true
minimum: 0
example: 13
media:
type: object
readOnly: true
description: Board media.
properties:
image_cover_url:
type: string
nullable: true
description: Board cover image.
example: https://i.pinimg.com/400x300/fd/cd/d5/fdcdd5a6d8a80824add0d054125cd957.jpg
pin_thumbnail_urls:
type: array
description: Board pin thumbnail urls.
items:
type: string
example:
- https://i.pinimg.com/150x150/b4/57/10/b45710f1ede96af55230f4b43935c4af.jpg
- https://i.pinimg.com/150x150/dd/ff/46/ddff4616e39c1935cd05738794fa860e.jpg
- https://i.pinimg.com/150x150/84/ac/59/84ac59b670ccb5b903dace480a98930c.jpg
- https://i.pinimg.com/150x150/4c/54/6f/4c546f521be85e30838fb742bfff6936.jpg
owner:
allOf:
- $ref: '#/components/schemas/BoardOwner'
type: object
readOnly: true
privacy:
type: string
default: PUBLIC
description: Privacy setting for a board. Learn more about secret boards and protected boards
enum:
- PUBLIC
- PROTECTED
- SECRET
required:
- name
Paginated:
type: object
properties:
items:
type: array
items:
type: object
bookmark:
type: string
nullable: true
required:
- items
parameters:
query_explicit_following:
description: Whether or not to include implicit user follows, which means followees with board follows. When explicit_following is True, it means we only want explicit user follows.
in: query
name: explicit_following
required: false
schema:
type: boolean
default: false
query_page_size:
name: page_size
description: Maximum number of items to include in a single page of the response. See documentation on Pagination for more information.
in: query
required: false
schema:
type: integer
minimum: 1
maximum: 250
default: 25
query_bookmark:
name: bookmark
description: Cursor used to fetch the next page of items
in: query
required: false
schema:
type: string
query_ad_account_id:
name: ad_account_id
description: Unique identifier of an ad account.
in: query
schema:
type: string
pattern: ^\d+$
maxLength: 18
query_website:
description: Website with path or domain only
in: query
name: website
required: true
schema:
type: string
example: mysite.test
securitySchemes:
pinterest_oauth2:
type: oauth2
flows:
authorizationCode:
authorizationUrl: https://www.pinterest.com/oauth/
tokenUrl: https://api.pinterest.com/v5/oauth/token
scopes:
ads:read: See all of your advertising data, including ads, ad groups, campaigns etc.
ads:write: Create, update, or delete ads, ad groups, campaigns etc.
billing:read: See all of your billing data, billing profile, etc.
billing:write: Create, update, or delete billing data, billing profiles, etc.
biz_access:read: See business access data
biz_access:write: Create, update, or delete business access data
boards:read: See your public boards, including group boards you join
boards:read_secret: See your secret boards
boards:write: Create, update, or delete your public boards
boards:write_secret: Create, update, or delete your secret boards
catalogs:read: See all of your catalogs data
catalogs:write: Create, update, or delete your catalogs data
pins:read: See your public Pins
pins:read_secret: See your secret Pins
pins:write: Create, update, or delete your public Pins
pins:write_secret: Create, update, or delete your secret Pins
user_accounts:read: See your user accounts and followers
user_accounts:write: Update your user accounts and followers
conversion_token:
type: http
scheme: bearer
description: This security scheme only applies to the conversion events endpoint (POST /ad_accounts/{ad_account_id}/events). This endpoint requires a bearer token generated via Ads Manager (ads.pinterest.com).
basic:
type: http
scheme: basic
x-tagGroups:
- name: Pin and Boards
tags:
- pins
- boards
- media
- aggregated_comments
- aggregated_pin_data
- user_account
- name: Campaign Management
tags:
- ad_accounts
- campaigns
- ad_groups
- ads
- product_group_promotions
- bulk
- name: Targeting
tags:
- audiences
- customer_lists
- keywords
- targeting_template
- audience_insights
- audience_sharing
- name: Ad Formats
tags:
- lead_forms
- lead_ads
- leads_export
- name: Billing
tags:
- billing
- order_lines
- terms_of_service
- name: Business Access
tags:
- business_access_assets
- business_access_invite
- business_access_relationships
- name: Conversions
tags:
- conversion_events
- conversion_tags
- name: Others
tags:
- integrations
- oauth
- resources
- search
- terms
- name: Shopping
tags:
- catalogs
- name: Deprecated
tags:
- product_groups