How to create products from csv lists with Python.

Coludus
Tourist
8 0 2

I am trying create products from csv item lists.

This is an example I am trying to do.

import shopify
import pandas as pd

product = shopify.Product()
df = pd.read_csv('example.csv')

for idx in df.index:
    row = df.loc[idx, :]
    name = row['name']
    product.title = name
    product.save()
    print(product.id)

 

However unfortunately, 'product.id' shows same number.

I want to make product with each product.id.

How can I do that?

 

Replies 0 (0)