Upload and sell straight away?

Discussion in 'Shapeways API' started by macouno, Aug 22, 2011.

  1. macouno
    macouno New Member
    Hi folks,

    I'm really thrilled about finding the API, and I've been playing around, but have a question or two (probably more to come).

    First and foremost.. What I would love to do is... allow people to modify/generate a model on my website... then it's uploaded to shapeways through the API. The person who modified the model then can buy a print from my shop (and I get a small percentage).

    Now... I seem to have the correct connection happening with SOAP. But it looks as if, after upload all you get is "succesfull", and no way to link my customer to the uploaded model.

    I also got this message when I first looked at the model "You have not yet agreed to our Terms & Conditions.". That seems to defeat the purpose of an API somewhat to me...

    So eh... To me the entire point of the API is... that I can automaticly upload models from my server to shapeways' server... and sell those to the people that generated them (with a small profit). And all that without me having to do anything manually...

    Is this possible at all? Am I making sense here?
  2. macouno
    macouno New Member
    I have progressed more already...

    The only thing that gets in my way is the "confirmation"... that I have to agree to the terms and conditions. If I could just get around that... then this'll work...

    Or do you purposely intend us to for instance have to e-mail our customers to tell them the model is available? That would be a bit... eh... well, not so smooth ;)
  3. macouno
    macouno New Member
    Ack... I'm too quick asking questions... I read the answer elsewhere.

    This line in the SoapAPI.php is the solution:
    $result = $this->client->submitModel($this->session, $model, null, 'generated-creator');

    It has to be 'generated-creator'... then your model is instantly for sale, and you get the ID of the model as the return value.

    Awesome! I'm sure I'll have more questions soon... but for now it looks like it's working!
  4. hans_lambermont
    hans_lambermont Shapeways Employee Dev Team
    Cool, I see you found the workaround for the T&C issue.

    -- Hans
  5. macouno
    macouno New Member
    Yes I did, thanks for having a look anyway.

    You can see what I've been up to here: http://www.shapewright.com/

    I haven't really run into any issues since yesterday. Would just like to figure out a quick way to calculate the volume of a model myself (for price estimates).

    I also haven't found a way to set in which materials a print should be available. I don't mind customers picking themselves, but it might be a good option for the API.
  6. electrobloom
    electrobloom New Member
    This is just brilliant! :eek:
  7. elchan
    elchan New Member
    The BUY button doesn't seem to do anything.