Discussion Forum: Thread 265461

 Author: mogli252 View Messages Posted By mogli252
 Posted: Mar 25, 2020 19:33
 Subject: Solution for wrong Brickstock prices?
 Viewed: 79 times
 Topic: Help
Cancel Message
Cancel
Reply to Message
Reply
BrickLink
ID Card

mogli252 (65)

Location:  Germany, Bayern
Member Since Contact Type Status
Jul 27, 2018 Contact Member Seller
Buying Privileges - OKSelling Privileges - OK
Store: Moglis Bricks
Hello there,

I am looking for help. I am working on a script to update my prices and I’d like
to share it with others, interested in verifying that it does what its supposed
to. And maybe improve it further.

I started my store about three months ago and since I started adding lots of
lots, I don’t know any more how to update my prices to last 6 month sales. Doing
it manually is too time consuming and boring.
I use Brickstock to manage my inventory, which works great, but as a known "bug"
it shows wrong prices outside US. So I started working on a Php script to do
the work for me and update the prices.

About the script:
I started with a script scraping the Bricklink price guide page, but with too
many requests I got blocked quickly, of course...
So I looked into the Api and after many attempts got it working now.

The script starts with an html form, where you can choose the item category to
update as well as item type. You also need the xml file of your inventory.
The script then scans your inventory for that category and gets the correct price
for that piece. From that it will create a new xml file with all info, ready
to be uploaded to the mass-update page on Bricklink.
What you need is some kind of server, that can run html and php code. I use Xamp
on my local machine.

It would be great to get some feedback here. Just contact me and I’ll send over
what I have so far.
I look forward to hearing from you.

Best
David

P.s. I am not a software engineer, I learned coding with several arduino project.
So don't be confused by my maybe wrong terminology.
 Author: mogli252 View Messages Posted By mogli252
 Posted: Mar 31, 2020 18:38
 Subject: Re: Solution for wrong Brickstock prices?
 Viewed: 38 times
 Topic: Help
Cancel Message
Cancel
Reply to Message
Reply
BrickLink
ID Card

mogli252 (65)

Location:  Germany, Bayern
Member Since Contact Type Status
Jul 27, 2018 Contact Member Seller
Buying Privileges - OKSelling Privileges - OK
Store: Moglis Bricks
anyone?
 Author: BrickSolution View Messages Posted By BrickSolution
 Posted: Apr 2, 2020 10:43
 Subject: Re: Solution for wrong Brickstock prices?
 Viewed: 16 times
 Topic: Help
Cancel Message
Cancel
Reply to Message
Reply
BrickLink
ID Card

BrickSolution (1)

Location:  Germany, Hamburg
Member Since Contact Type Status
Sep 4, 2018 Contact Member Seller
Buying Privileges - OKSelling Privileges - OK
Store: BrickSolution
In Help, mogli252 writes:
  anyone?

Hi,
regards the wrong prices shown in BrickStock:

BrickStock is working with USD prices and does not support real time exchange
rates.
You can change the exchange rate in your preferences.
I am working with USD-EUR 0.9 rate (0.92 would be accurate at the moment), so
I temporarily see 'wrong' prices in BrickStock, but the upload function
in BrickStock is working with USD prices so your inventory will convert on BL
with the real time exchange rate (0.92).

Just change the exchange rate every time you are using BrickStock and you will
be fine.

Best,
Sven.
 
 Author: mogli252 View Messages Posted By mogli252
 Posted: Apr 2, 2020 12:24
 Subject: Re: Solution for wrong Brickstock prices?
 Viewed: 33 times
 Topic: Help
Cancel Message
Cancel
Reply to Message
Reply
BrickLink
ID Card

mogli252 (65)

Location:  Germany, Bayern
Member Since Contact Type Status
Jul 27, 2018 Contact Member Seller
Buying Privileges - OKSelling Privileges - OK
Store: Moglis Bricks
Hi Sven,

thank you so much for your reply.
Yes, USD is hard coded and Brickstock uses a different Api that is not documented.
Also, isn't the problem with Brickstock that it doesn't handle taxes
correct? Just something I read.

I know about that option in Brickstock, but i cant get it to work here. Not 2
months ago, not today
I uploaded 19 new lots today, but only 7 of those had almost correct prices.
And prices are all over the place, some lower, some higher.
No Idea what i am doing wrong...

Best
David
 Author: Teup View Messages Posted By Teup
 Posted: Apr 2, 2020 14:08
 Subject: Re: Solution for wrong Brickstock prices?
 Viewed: 32 times
 Topic: Help
Cancel Message
Cancel
Reply to Message
Reply
BrickLink
ID Card

Teup (4468)

Location:  Netherlands, Utrecht
Member Since Contact Type Status
May 6, 2004 Contact Member Seller
Buying Privileges - OKSelling Privileges - OK
Store Closed Store: The T-workshop
In Help, mogli252 writes:
  Hi Sven,

thank you so much for your reply.
Yes, USD is hard coded and Brickstock uses a different Api that is not documented.
Also, isn't the problem with Brickstock that it doesn't handle taxes
correct? Just something I read.

I know about that option in Brickstock, but i cant get it to work here. Not 2
months ago, not today
I uploaded 19 new lots today, but only 7 of those had almost correct prices.
And prices are all over the place, some lower, some higher.
No Idea what i am doing wrong...

Best
David

- True, most of the time they will be lower, as on Bricklink VAT is included
while Brickstock downloads prices without VAT. In the most extreme case, all
offers are located in the EU by VAT registered sellers, in which case the price
in Brickstock can be almost 20% too low. (rare, but possible)

- They can be equal when the parts are only offered by sellers outside
the EU who don't have VAT either way. Then it doesn't matter if the price
is displayed including or excluding VAT, because there's no VAT added anyway.

- Higher is unusual, but it is also possible. Because besides the VAT
problem, there is a second problem. There's a difference in how Last 6 Months
Sales prices are calculated - this is a bit technical. Bricklink converts all
transactions that were not in Euro to Euro with the exchange rate at the date
of purchase. Brickstock, however, downloads the Last 6 Months Sales first converted
into Dollar, and then leaves it up to you to convert it back to Euro, which you
probably will do with today's exchange rate. If there has been significant
fluctuation between the Euro and the Dollar, the Last 6 Months Sales prices can
be either higher or lower in Brickstock than they are on Bricklink. This only
applies to Last 6 Months Sales. Current Average is just the current average in
today's exchange rate, as far as I can see not much can go wrong there (except
the fact that VAT is not included on Brickstock).

This is what I understand... maybe there are more things going on I don't
know yet.. but these things are certain and confirmed.
 Author: Teup View Messages Posted By Teup
 Posted: Apr 1, 2020 06:55
 Subject: Re: Solution for wrong Brickstock prices?
 Viewed: 46 times
 Topic: Help
Cancel Message
Cancel
Reply to Message
Reply
BrickLink
ID Card

Teup (4468)

Location:  Netherlands, Utrecht
Member Since Contact Type Status
May 6, 2004 Contact Member Seller
Buying Privileges - OKSelling Privileges - OK
Store Closed Store: The T-workshop
In Help, mogli252 writes:
  Hello there,

I am looking for help. I am working on a script to update my prices and I’d like
to share it with others, interested in verifying that it does what its supposed
to. And maybe improve it further.

I started my store about three months ago and since I started adding lots of
lots, I don’t know any more how to update my prices to last 6 month sales. Doing
it manually is too time consuming and boring.
I use Brickstock to manage my inventory, which works great, but as a known "bug"
it shows wrong prices outside US. So I started working on a Php script to do
the work for me and update the prices.

About the script:
I started with a script scraping the Bricklink price guide page, but with too
many requests I got blocked quickly, of course...
So I looked into the Api and after many attempts got it working now.

The script starts with an html form, where you can choose the item category to
update as well as item type. You also need the xml file of your inventory.
The script then scans your inventory for that category and gets the correct price
for that piece. From that it will create a new xml file with all info, ready
to be uploaded to the mass-update page on Bricklink.
What you need is some kind of server, that can run html and php code. I use Xamp
on my local machine.

It would be great to get some feedback here. Just contact me and I’ll send over
what I have so far.
I look forward to hearing from you.

Best
David

P.s. I am not a software engineer, I learned coding with several arduino project.
So don't be confused by my maybe wrong terminology.

Very interesting, it's really a shame you didn't get any replies yet
because pricing is a crucially important topic, and as you say Brickstock is
not accurate outside the US, which is very unfortunate.

I am a really low tech hobby programmer and what I do is just scraping the price
guide detail pages. This takes time but it works. I rarely get blocked. It works
pretty well and the rest of the process is the same as what you describe - read
in the inventory file, download the prices, match and replace them, and export
mass inventory updates. Not for the whole inventory at a time, but for one or
two categories per file.

However, I heard that Bricklink is going to replace some old pages with ones
that I cannot scrape because they can't be downloaded by the url. This makes
me worried if my method is going to keep on working in the future. As we all
know Bricklink never works on features that users are requesting so I doubt that
we are going to get a good simple to use API like Rebrickable and Brickowl have,
where you simply have an url to a plain text html that contains the data you
need.

I would be very interested in a tool that would allow me to do this without my
scraping method, but I am not skilled enough to be able to use the cryptic Bricklink
API. I could share with you some details of my current method. I can't help
you with the technical side, but I have some formulas for pricing policies that
could be useful to incorporate. Just send me a message if you're interested.
 Author: mogli252 View Messages Posted By mogli252
 Posted: Apr 2, 2020 12:43
 Subject: Re: Solution for wrong Brickstock prices?
 Viewed: 25 times
 Topic: Help
Cancel Message
Cancel
Reply to Message
Reply
BrickLink
ID Card

mogli252 (65)

Location:  Germany, Bayern
Member Since Contact Type Status
Jul 27, 2018 Contact Member Seller
Buying Privileges - OKSelling Privileges - OK
Store: Moglis Bricks
Hi Teup,

thank you very much for your reply!
I will send you a message.

Best David