Documentation SOAP to REST

  • klaus_schneider

    289 berichten

    Duitsland

    Hello,
    we don't use PHP.
    In order to carry out the API conversion, we need the structure of the URLs for the request.
    Please add this information to the documentation.
    Regards Klaus
  • @thomas
    Beheerder

    348 berichten

    België

    Hello Klaus,

    You can find all URLs here: Link (https)

    You can find the structure of the URLs by clicking on them.

    Unfortunately we don't have examples with languages other than PHP. Which one do you use?

    Kind Regards,
    --
    Thomas
    Delcampe Team
  • klaus_schneider

    289 berichten

    Duitsland

    Hello,
    Yes, this list is known, but that's not enough, I need examples with data / the parameters of how the URLs are structured. So what comes out of PHP and what is exactly transferred to the server.
    Regard Klaus
  • @thomas
    Beheerder

    348 berichten

    België

    Hello,
    Yes, this list is known, but that's not enough, I need examples with data / the parameters of how the URLs are structured. So what comes out of PHP and what is exactly transferred to the server.
    Regard Klaus
    • Aangemaakt 25 sep 2020 op 05:11
    • #1192054
    Hello Klaus,

    For example to add an item Link (https) :

    ** with HTTP:

    POST /item?token=***your seller token*** HTTP/1.1
    Host: Link (https)
    Content-Type: application/x-www-form-urlencoded

    type=fixedPrice&item[id_country]=3&item[id_category]=1242&item[fixed_price]=15.00&item[currency]=EUR&item[title]=My title&item[personal_reference]=My personal Ref8&item[qty]=1&item[duration]=28&item[description]=My description&item[renew]=0&item[option_lastminutebidding]=&item[option_privatebidding]=&item[option_subtitle]=&item[subtitle]=&item[option_boldtitle]=&item[option_highlight]=&item[option_coloredborder]=&item[option_toplisting]=&item[option_topcategory]=&item[option_topmain]=&item[option_keepoptionsonrenewal]=&item[prefered_end_day]=mon&item[prefered_end_hour]=15:00&item[images][0]= Link (https)

    ** with cURL:

    curl --location --request POST ' Link (https) seller token***' \
    --header 'Content-Type: application/x-www-form-urlencoded' \
    --data-urlencode 'type=fixedPrice' \
    --data-urlencode 'item[id_country]=3' \
    --data-urlencode 'item[id_category]=1242' \
    --data-urlencode 'item[fixed_price]=15.00' \
    --data-urlencode 'item[currency]=EUR' \
    --data-urlencode 'item[title]=My title' \
    --data-urlencode 'item[personal_reference]=My personal Ref' \
    --data-urlencode 'item[qty]=1' \
    --data-urlencode 'item[duration]=28' \
    --data-urlencode 'item[description]=My description' \
    --data-urlencode 'item[renew]=0' \
    --data-urlencode 'item[option_lastminutebidding]=' \
    --data-urlencode 'item[option_privatebidding]=' \
    --data-urlencode 'item[option_subtitle]=' \
    --data-urlencode 'item[subtitle]=' \
    --data-urlencode 'item[option_boldtitle]=' \
    --data-urlencode 'item[option_highlight]=' \
    --data-urlencode 'item[option_coloredborder]=' \
    --data-urlencode 'item[option_toplisting]=' \
    --data-urlencode 'item[option_topcategory]=' \
    --data-urlencode 'item[option_topmain]=' \
    --data-urlencode 'item[option_keepoptionsonrenewal]=' \
    --data-urlencode 'item[prefered_end_day]=mon' \
    --data-urlencode 'item[prefered_end_hour]=15:00' \
    --data-urlencode 'item[images][0]= Link (https) '\
    --data-urlencode 'item[images][1]= Link (https) '\

    I hope it's clear enough, otherwise tell me.
    --
    Thomas
    Delcampe Team
  • klaus_schneider

    289 berichten

    Duitsland

    OK Thanks, i think we can start with this, can you send me a example for the compleed authentification procedure in this structure.
  • @thomas
    Beheerder

    348 berichten

    België

    To authenticate, the behavior is pretty much the same as on SOAP. You make a call with your API key and you will receive a connection token in XML.

    **HTTP

    POST /seller HTTP/1.1
    Host: Link (https)
    Content-Type: application/x-www-form-urlencoded

    apikey=***your_api_key***

    **cURL

    curl --location --request POST ' Link (https) ' \
    --header 'Content-Type: application/x-www-form-urlencoded' \
    --data-urlencode 'apikey=***your_api_key***'

    --
    Thomas
    Delcampe Team
  • postcarddatabase

    65 berichten

    België

    just a small question concerning the migration from soap to rest:

    i figure that i don't need to change anything to my notification handler, right? as this doesn't do requests towards delcampe

    just making sure at least this will keep working :)
  • @thomas
    Beheerder

    348 berichten

    België

    just a small question concerning the migration from soap to rest:

    i figure that i don't need to change anything to my notification handler, right? as this doesn't do requests towards delcampe

    just making sure at least this will keep working :)
    • Aangemaakt 17 nov 2020 op 09:52
    • #1211998
    Hello postcarddatabase,

    Indeed you don't need to change anything as the notifications remain the same.

    Best Regards,
    --
    Thomas
    Delcampe Team
  • klaus_schneider

    289 berichten

    Duitsland

    Hello,
    please can you give me the exact link structure for the array POSTs (/item/rating and /item) for example like this

    DELETE /item/110540589700?token=xxx&reason=NotAvailableItem&priority=1 HTTP/1.1

    best wishes
  • klaus_schneider

    289 berichten

    Duitsland

    Hello Klaus,

    For example to add an item Link (https) :

    ** with HTTP:

    POST /item?token=***your seller token*** HTTP/1.1
    Host: Link (https)
    Content-Type: application/x-www-form-urlencoded

    type=fixedPrice&item[id_country]=3&item[id_category]=1242&item[fixed_price]=15.00&item[currency]=EUR&item[title]=My title&item[personal_reference]=My personal Ref8&item[qty]=1&item[duration]=28&item[description]=My description&item[renew]=0&item[option_lastminutebidding]=&item[option_privatebidding]=&item[option_subtitle]=&item[subtitle]=&item[option_boldtitle]=&item[option_highlight]=&item[option_coloredborder]=&item[option_toplisting]=&item[option_topcategory]=&item[option_topmain]=&item[option_keepoptionsonrenewal]=&item[prefered_end_day]=mon&item[prefered_end_hour]=15:00&item[images][0]= Link (https)

    ** with cURL:

    curl --location --request POST ' Link (https) seller token***' \
    --header 'Content-Type: application/x-www-form-urlencoded' \
    --data-urlencode 'type=fixedPrice' \
    --data-urlencode 'item[id_country]=3' \
    --data-urlencode 'item[id_category]=1242' \
    --data-urlencode 'item[fixed_price]=15.00' \
    --data-urlencode 'item[currency]=EUR' \
    --data-urlencode 'item[title]=My title' \
    --data-urlencode 'item[personal_reference]=My personal Ref' \
    --data-urlencode 'item[qty]=1' \
    --data-urlencode 'item[duration]=28' \
    --data-urlencode 'item[description]=My description' \
    --data-urlencode 'item[renew]=0' \
    --data-urlencode 'item[option_lastminutebidding]=' \
    --data-urlencode 'item[option_privatebidding]=' \
    --data-urlencode 'item[option_subtitle]=' \
    --data-urlencode 'item[subtitle]=' \
    --data-urlencode 'item[option_boldtitle]=' \
    --data-urlencode 'item[option_highlight]=' \
    --data-urlencode 'item[option_coloredborder]=' \
    --data-urlencode 'item[option_toplisting]=' \
    --data-urlencode 'item[option_topcategory]=' \
    --data-urlencode 'item[option_topmain]=' \
    --data-urlencode 'item[option_keepoptionsonrenewal]=' \
    --data-urlencode 'item[prefered_end_day]=mon' \
    --data-urlencode 'item[prefered_end_hour]=15:00' \
    --data-urlencode 'item[images][0]= Link (https) '\
    --data-urlencode 'item[images][1]= Link (https) '\

    I hope it's clear enough, otherwise tell me.
    --
    Thomas
    Delcampe Team
    • Aangemaakt 25 sep 2020 op 06:02
    • #1192075
    Hello,

    please, what ist the type for auction format ?

    bw
  • klaus_schneider

    289 berichten

    Duitsland

    Hello Klaus,

    For example to add an item Link (https) :

    ** with HTTP:

    POST /item?token=***your seller token*** HTTP/1.1
    Host: Link (https)
    Content-Type: application/x-www-form-urlencoded

    type=fixedPrice&item[id_country]=3&item[id_category]=1242&item[fixed_price]=15.00&item[currency]=EUR&item[title]=My title&item[personal_reference]=My personal Ref8&item[qty]=1&item[duration]=28&item[description]=My description&item[renew]=0&item[option_lastminutebidding]=&item[option_privatebidding]=&item[option_subtitle]=&item[subtitle]=&item[option_boldtitle]=&item[option_highlight]=&item[option_coloredborder]=&item[option_toplisting]=&item[option_topcategory]=&item[option_topmain]=&item[option_keepoptionsonrenewal]=&item[prefered_end_day]=mon&item[prefered_end_hour]=15:00&item[images][0]= Link (https)

    ** with cURL:

    curl --location --request POST ' Link (https) seller token***' \
    --header 'Content-Type: application/x-www-form-urlencoded' \
    --data-urlencode 'type=fixedPrice' \
    --data-urlencode 'item[id_country]=3' \
    --data-urlencode 'item[id_category]=1242' \
    --data-urlencode 'item[fixed_price]=15.00' \
    --data-urlencode 'item[currency]=EUR' \
    --data-urlencode 'item[title]=My title' \
    --data-urlencode 'item[personal_reference]=My personal Ref' \
    --data-urlencode 'item[qty]=1' \
    --data-urlencode 'item[duration]=28' \
    --data-urlencode 'item[description]=My description' \
    --data-urlencode 'item[renew]=0' \
    --data-urlencode 'item[option_lastminutebidding]=' \
    --data-urlencode 'item[option_privatebidding]=' \
    --data-urlencode 'item[option_subtitle]=' \
    --data-urlencode 'item[subtitle]=' \
    --data-urlencode 'item[option_boldtitle]=' \
    --data-urlencode 'item[option_highlight]=' \
    --data-urlencode 'item[option_coloredborder]=' \
    --data-urlencode 'item[option_toplisting]=' \
    --data-urlencode 'item[option_topcategory]=' \
    --data-urlencode 'item[option_topmain]=' \
    --data-urlencode 'item[option_keepoptionsonrenewal]=' \
    --data-urlencode 'item[prefered_end_day]=mon' \
    --data-urlencode 'item[prefered_end_hour]=15:00' \
    --data-urlencode 'item[images][0]= Link (https) '\
    --data-urlencode 'item[images][1]= Link (https) '\

    I hope it's clear enough, otherwise tell me.
    --
    Thomas
    Delcampe Team
    • Aangemaakt 25 sep 2020 op 06:02
    • #1192075
    Hello,
    OK, we try this for setFeedback

    POST /item/1133270464/buyer/rating?token=xxx&item[ratingValue]=100&item[comment]=Alles%20OK%20%2D%20Vielen%20Dank HTTP/1.1

    but it doesn´t work, response is

    You must send a comment for ratings under 100%

    so we think parameters are not right for array structure.

    bw
  • @thomas
    Beheerder

    348 berichten

    België

    Hello,
    please can you give me the exact link structure for the array POSTs (/item/rating and /item) for example like this

    DELETE /item/110540589700?token=xxx&reason=NotAvailableItem&priority=1 HTTP/1.1

    best wishes
    • Aangemaakt 21 dec 2020 op 09:17
    • #1226105
    Hello klaus_schneider,

    1) The structure of your link is correct. Just pay attention that the id of your item is 1105405897 (without the 00 at the end).

    2) The type of auction is 'auction'. Link (https)

    3) Indeed, there are several errors in your call. As the call uses the POST HTTP method, you cannot pass the data through the URL. Then the data should not be passed as an 'item' array.
    Use the multipart/form-data Content-Type: Link (https)

    Best Regards,
    --
    Thomas
    Delcampe Team
  • klaus_schneider

    289 berichten

    Duitsland

    Hello klaus_schneider,

    1) The structure of your link is correct. Just pay attention that the id of your item is 1105405897 (without the 00 at the end).

    2) The type of auction is 'auction'. Link (https)

    3) Indeed, there are several errors in your call. As the call uses the POST HTTP method, you cannot pass the data through the URL. Then the data should not be passed as an 'item' array.
    Use the multipart/form-data Content-Type: Link (https)

    Best Regards,
    --
    Thomas
    Delcampe Team
    • Aangemaakt 21 dec 2020 op 11:59
    • #1226237
    Hi there,
    the function setFeedback needs 1 sec with SOAP, with REST it takes 1 minute until the function comes back with the answer or the error message. Where is the problem ?
    Kind regards
  • klaus_schneider

    289 berichten

    Duitsland

    Hello klaus_schneider,

    1) The structure of your link is correct. Just pay attention that the id of your item is 1105405897 (without the 00 at the end).

    2) The type of auction is 'auction'. Link (https)

    3) Indeed, there are several errors in your call. As the call uses the POST HTTP method, you cannot pass the data through the URL. Then the data should not be passed as an 'item' array.
    Use the multipart/form-data Content-Type: Link (https)

    Best Regards,
    --
    Thomas
    Delcampe Team
    • Aangemaakt 21 dec 2020 op 11:59
    • #1226237
    Hello,
    by the REST funktion

    itemFixedPriceClosedSold

    are the wrong parameter names in the dokumentation (from auction type).

    best wishes
  • @fred
    Beheerder

    149 berichten

    België

    Hello,
    by the REST funktion

    itemFixedPriceClosedSold

    are the wrong parameter names in the dokumentation (from auction type).

    best wishes
    • Aangemaakt 24 dec 2020 op 22:00
    • #1227710
    Hi @klaus_schneider,

    Thank you, we'll fix the documentation as soon as possible.

    Regards,
    --
    Fred
    Delcampe Team
  • postcarddatabase

    65 berichten

    België

    It all seems to work. I have a question which I never bothered to solve with the Soap API either, but I guess now is the time.

    How should I, in PHP, encode strings so " and ' are represented correctly? In the past I always escaped them in order to not break my code, but it is shown on Delcampe as e. g. \".

    I tried now to do stripslashes() and add urldecode() but a " then shows on Delcampe as %22 :).

    Thing is, I can encode it any way I want but it depends on how Delcampe decodes it, I think.

    What should I do?
  • klaus_schneider

    289 berichten

    Duitsland

    Hi there,
    the function setFeedback needs 1 sec with SOAP, with REST POST it takes 1 minute until the function comes back with the answer or the error message, also with add item. Where is the problem ? This is a big problem...
    Kind regards
  • klaus_schneider

    289 berichten

    Duitsland

    It all seems to work. I have a question which I never bothered to solve with the Soap API either, but I guess now is the time.

    How should I, in PHP, encode strings so " and ' are represented correctly? In the past I always escaped them in order to not break my code, but it is shown on Delcampe as e. g. \".

    I tried now to do stripslashes() and add urldecode() but a " then shows on Delcampe as %22 :).

    Thing is, I can encode it any way I want but it depends on how Delcampe decodes it, I think.

    What should I do?
    • Aangemaakt 28 dec 2020 op 16:50
    • #1228862
    Hi,

    for special characters you must use the numeric entitys, for exampe:

    ASCII="ä" :"ö" :"ü" :"Ä" :"Ö" :"Ü" :"ß" :"ï" :"ë" :"ÿ" :"Ï" :"Ë"
    DELC="ä" :"ö" :"ü" :"Ä" :"Ö" :"Ü" :"ß" :"ï" :"ë" :"ÿ" :"Ï" :"Ë"

    ASCII="á" :"ó" :"ú" :"é" :"Á" :"Ó" :"Ú" :"É" :"í" :"Í" :"ý" :"Ý"
    DELC="á" :"ó" :"ú" :"é" :"Á" :"Ó" :"Ú" :"É" :"í" :"Í" :"ý" :"Ý"

    best wishes
  • klaus_schneider

    289 berichten

    Duitsland

    It all seems to work. I have a question which I never bothered to solve with the Soap API either, but I guess now is the time.

    How should I, in PHP, encode strings so " and ' are represented correctly? In the past I always escaped them in order to not break my code, but it is shown on Delcampe as e. g. \".

    I tried now to do stripslashes() and add urldecode() but a " then shows on Delcampe as %22 :).

    Thing is, I can encode it any way I want but it depends on how Delcampe decodes it, I think.

    What should I do?
    • Aangemaakt 28 dec 2020 op 16:50
    • #1228862
    OK, ist is not visible in this forum, format is

    & # xxxx;

    without blanks for example xxxx = 228 für ä, 246 for ö and so on, you can find the compleed table in the web (Unicode Decimal Code)... Wikipedia aso...

    best wishes
  • klaus_schneider

    289 berichten

    Duitsland

    Hello,

    Have a good new year....

    All functions now switched from SOAP to REST

    but

    POST-Types (PUT is not testet by now, but i think it is the same) for feedback and item have a Time (timeout) Problem, all POSTs need 60 seconds before the OK Response comes back. Failure response comes promptly. So it is not usable. Please do not switch off the SOAP System before this problem is fixed/cleared. This functions we have not switched yet.

    best wishes
  • postcarddatabase

    65 berichten

    België

    I solved my little issue by doing stripslashes() only as I noticed in the PHP documentation the http_build_query() performs the url encoding by itself.

    Best wishes!
  • @thomas
    Beheerder

    348 berichten

    België

    I solved my little issue by doing stripslashes() only as I noticed in the PHP documentation the http_build_query() performs the url encoding by itself.

    Best wishes!
    • Aangemaakt 4 jan 2021 op 15:22
    • #1231385
    Hello postcarddatabase,

    Glad to read that you were able to solve your problem.

    Best wishes,
    --
    Thomas
    Delcampe Team
  • postcarddatabase

    65 berichten

    België

    Hi Delcampe, I notice auctions put online with REST that have ended yesterday at 20:30 are still in my 'ongoing with bids' list. I cannot invoice the clients. However when I go to the auction it says it ended. Example:

    Link (https)

    Also see screenshot in attach of the 'ongoing with bids' list. Screenshot made now, auctions in the list that ended yesterday.

    Is this an issue with the api or is there something else going on?
  • @thomas
    Beheerder

    348 berichten

    België

    Hi Delcampe, I notice auctions put online with REST that have ended yesterday at 20:30 are still in my 'ongoing with bids' list. I cannot invoice the clients. However when I go to the auction it says it ended. Example:

    Link (https)

    Also see screenshot in attach of the 'ongoing with bids' list. Screenshot made now, auctions in the list that ended yesterday.

    Is this an issue with the api or is there something else going on?
    • Aangemaakt 20 jan 2021 op 03:23
    • #1236991
    Hello postcarddatabase,

    We have indeed encountered problems with a server last night. This resulted in processing delays. The issue has been identified and corrected, the delays are being reduced.

    Everything should be back to normal in a couple of hours.

    We're sorry for the inconvenience,
    Kind Regards,
    --
    Thomas
    Delcampe Team
  • postcarddatabase

    65 berichten

    België

    ok

Word lid van de verzamelaars-community!

Registreren Aanmelden