Getting started with the Web API

Sign up with Converted.in Create account and verify Email and Create Api Store

Get Api Key and Secret Key To use Them in Web Api

Steps

You must follow this steps to add your store data

Auth Apikey

post
Auth ApiKey

https://app.converted.in/sdk/login
This endpoint Use for Auth Api Key And get token
Request
Response
Request
Headers
Content-Type
required
string
application/json
Accept
required
string
application/json
Body Parameters
api_key
required
string
235984A44552205588
secret_key
required
string
sasa77dsdsdmmkiiioallla
Response
200: OK
{
"access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwOlwvXC9sb2NhbGhvc3Q6ODAwMFwvc2RrXC9sb2dpbiIsImlhdCI6MTU5NjY3NDMyOCwiZXhwIjoxNjI3Nzc4MzI4LCJuYmYiOjE1OTY2NzQzMjgsImp0aSI6IlViQnEzeUk0d2I4ZHVkak4iLCJzdWIiOjgsInBydiI6ImIzOWRmN2MxY2JmYjhmZWI4NTFkZGJhYzQ2NzE3YzczZmJkZmY3MmIifQ.FC3gcVqXGpvj1EMGxQEsRP-15AarJK6_3RAcYoAdf9w",
"token_type": "bearer",
"expires_in": 31104000
}
401: Unauthorized
{
"error": "Unauthorized"
}

Body

json
json
{
"api_key":"637abf97100b36a04ac06a4703302db5",
"secret_key":"YbJwooKgUywpEXgaVX6mwfC3TsaorSch"
}

Products

post
Add Products

https://app.converted.in/sdk/products
this endpoint allows you to add Products
Request
Response
Request
Headers
Authentication
required
string
Bearer Token
Content-Type
required
string
application/json
Accept
required
string
application/json
Response
200: OK
{
"status": "done"
}
401: Unauthorized
{
"message": "Unauthenticated."
}

Body

json
json
{
"products":[
{
"id":2493745758295,
"title":"6 in 1 Professional Pet Grooming Kit Box",
"body_html":"<ul class=\"a-unordered-list a-vertical a-spacing-none\">\n<li><span class=\"a-list-item\">Everyday Pet Grooming Set Consists of All Essential Tools: Deshedding Brush, Grooming Brush, Dematting Comb, Grooming Comb, and Nail Trimmer.<\/span><\/li>\n<li><span class=\"a-list-item\">Professional grade brush set: Keep your four-legged friend's hair healthy. Safely remove mats. Fluff, detangle and remove excess hair without hurting your pet.<\/span><\/li>\n<li><span class=\"a-list-item\">Comfortable and durable set: No need for replacements, this brush set is made to last with the best anti-slip handle.<\/span><\/li>\n<li><span class=\"a-list-item\">Perfect for medium and long-haired pets. Easy to clean<\/span><\/li>\n<\/ul>",
"vendor":"The HOMEGROOMER",
"product_type":"",
"handle":"6-in-1-professional-grooming-kit",
"published_at":"2019-04-23T10:54:15+02:00",
"template_suffix":"",
"published_scope":"web",
"tags":"",
"variants":[
{
"price":"44.95",
"compare_at_price":"64.99",
"weight":0,
"weight_unit":"lb",
"inventory_quantity":0,
}
],
"images":[
{
"position":1,
"width":600,
"height":600,
"src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0059\/4673\/6722\/products\/6_in_1_Professional_Pet_Grooming_Kit_Box_3.jpg?v=1556010134"
}
],
"image":{
"position":1,
"width":600,
"height":600,
"src":"https:\/\/cdn.shopify.com\/s\/files\/1\/0059\/4673\/6722\/products\/6_in_1_Professional_Pet_Grooming_Kit_Box_3.jpg?v=1556010134",
}
}
]
}

Customers

post
Add Customers

https://app.converted.in/sdk/customers
This endpoint allows you to add Customers
Request
Response
Request
Headers
Authentication
required
string
Bearer Token
Content-Type
required
string
application/json
Accept
required
string
application/json
Response
200: OK
{
"status": "done"
}
401: Unauthorized
{
"message": "Unauthenticated."
}

Body

json
json
{
"customers":[
{
"id":3381736767570,
"email":"carolkavanagh7@gmail.com",
"accepts_marketing":true,
"created_at":"2020-07-06T07:44:33+02:00",
"first_name":"Carol",
"last_name":"Kavanagh",
"orders_count":1,
"state":"disabled",
"total_spent":"34.97",
"last_order_id":2470484017234,
"phone":null,
"currency":"USD",
"addresses":[
{
"first_name":"Carol",
"last_name":"Kavanagh",
"company":null,
"address1":"LOT 3 Luke Price Street",
"address2":null,
"city":"Pingaring",
"province":"Western Australia",
"country":"Australia",
"zip":"6357",
"phone":"",
"name":"Carol Kavanagh",
"province_code":"WA",
"country_code":"AU",
"country_name":"Australia",
"default":true
}
]
}
]
}

Orders

post
Add Orders

https://app.converted.in/sdk/orders
this endpoint allows you to add orders
Request
Response
Request
Headers
Authentication
required
string
Bearer Token
Content-Type
required
string
application/json
Accept
required
string
application/json
Response
200: OK
{
"status": "done"
}
401: Unauthorized
{
"message": "Unauthenticated."
}

Body

json
json
{
"orders":[
{
"id":2470484017234,
"created_at":"2020-07-06T07:46:03+02:00",
"total_price":"34.97",
"subtotal_price":"34.97",
"total_weight":0,
"total_tax":"0.00",
"taxes_included":false,
"currency":"USD",
"financial_status":"paid",
"confirmed":true,
"total_discounts":"0.00",
"landing_site":"\/collections\/accesories\/products\/usb-rechargeable-dog-hair-trimmer?utm_source=Pinterest&utm_medium=cpc&utm_term=Search&utm_content=Video&utm_campaign=PT_Pinterest&pp=1",
"total_price_usd":"34.97",
"phone":null,
"customer_locale":"en",
"order_number":4198,
"payment_gateway_names":[
"paypal"
],
"processing_method":"express",
"source_name":"web",
"contact_email":"carolkavanagh7@gmail.com",
"presentment_currency":"USD",
"line_items":[
{
"product_id":47652658856232,
"quantity":1,
"requires_shipping":true,
"price":"34.97",
"total_discount":"0.00",
}
],
"billing_address":{
"country_code":"US",
},
"customer":{
"id":3381736767570,
}
}
]
}

Draft Orders

post
Add Draft Orders

https://app.converted.in/sdk/draft_orders
this endpoint allows you to add draft orders
Request
Response
Request
Headers
Authentication
required
string
Bearer Token
Content-Type
required
string
application/json
Accept
required
string
application/json
Response
200: OK
{
"status": "done"
}
401: Unauthorized
{
"message": "Unauthenticated."
}

Body

json
json
{
"draft_orders":[
{
"id":168642805842,
"created_at":"2019-06-04T13:34:50+02:00",
"updated_at":"2019-06-04T13:34:54+02:00",
"tax_exempt":false,
"completed_at":null,
"name":"#D79",
"status":"open",
"line_items":[
{
"product_id":2492460400722,
"quantity":1,
"requires_shipping":true,
"price":"24.99",
}
],
"billing_address":{
"country_code":"US",
},
"total_price":"24.99",
"subtotal_price":"24.99",
"total_tax":"0.00",
"customer":{
"id":1312581910610,
}
}
]
}

Abandoned Checkouts

post
Add Abandoned Checkouts

https://app.converted.in/sdk/abandoned_checkouts
this endpoint allows you to add Abandoned Checkouts
Request
Response
Request
Headers
Authentication
required
string
Bearer Token
Content-Type
required
string
application/json
Accept
required
string
application/json
Response
200: OK
{
"status": "done"
}
401: Unauthorized
{
"message": "Unauthenticated."
}

Body

json
json
{
"checkouts":[
{
"id":7451316387922,
"token":"4090a74b886e192d15e26917f8b845d4",
"cart_token":"e215335695c0c641e05d54566241b7d1",
"email":"teachercrawford@yahoo.com",
"created_at":"2019-03-01T21:05:49+02:00",
"referring_site":"http:\/\/instagram.com\/",
"taxes_included":false,
"total_weight":0,
"currency":"USD",]
"phone":null,
"customer_locale":"en",
"line_items":[
{
"product_id":299556337746,
"quantity":1,
"requires_shipping":true,
"price":"49.97"
}
],
"source_name":"web",
"presentment_currency":"USD",
"total_discounts":"0.00",
"total_price":"49.97",
"total_tax":"0.00",
"subtotal_price":"49.97",
"customer":{
"id":119789098722,
}
}
]
}

Run Segments

post
Run Segment

https://app.converted.in/sdk/run_segments
This endpoint allows you to run segment after you add products and customers and orders and abandoned checkout and after any update
Request
Response
Request
Headers
Authentication
required
string
Bearer Token
Content-Type
required
string
application/json
Accept
required
string
application/json
Body Parameters
run
required
boolean
true
Response
200: OK
{
"status": "done"
}
401: Unauthorized
{
"message": "Unauthenticated."
}

Body

json
json
{
"run":true
}