jenschude
(Jens Schulze)
February 8, 2018, 10:19am
1
Hi,
I’m generating a postman collection in my CI environment. As the described API has a lot of endpoints and features the collection is quite big. As I was not able to upload the pretty printed version with a size of 1.6 MB I used a compressed output which reduced the size to 560KB. Now I was able to upload the collection file using POST. But when I’m trying to update the collection using PUT the request always ends up in a 500 error.
Is there any way to get the update working using the API . Or do I have to always delete the collection and to POST it again?
kunagpal
(Kunal Nagpal)
February 13, 2018, 9:07pm
2
Hey @jenschude , you can use the Postman API to update collections programmatically. The API is documented here: https://docs.api.getpostman.com/#8ca888b7-ef54-f3b4-312f-3f3e2e2cf04e
jenschude
(Jens Schulze)
February 14, 2018, 8:19am
3
Maybe I hadn’t been clear enough.
I’m using the Postman API to update collections programmatically.
* Trying 107.23.32.145...
* TCP_NODELAY set
* Connected to api.getpostman.com (107.23.32.145) port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* Cipher selection: ALL:!EXPORT:!EXPORT40:!EXPORT56:!aNULL:!LOW:!RC4:@STRENGTH
* successfully set certificate verify locations:
* CAfile: /etc/ssl/cert.pem
CApath: none
* TLSv1.2 (OUT), TLS handshake, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Client hello (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS change cipher, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES128-GCM-SHA256
* ALPN, server did not agree to a protocol
* Server certificate:
* subject: OU=Domain Control Validated; OU=PositiveSSL Wildcard; CN=*.getpostman.com
* start date: Apr 10 00:00:00 2015 GMT
* expire date: Apr 9 23:59:59 2018 GMT
* subjectAltName: host "api.getpostman.com" matched cert's "*.getpostman.com"
* issuer: C=GB; ST=Greater Manchester; L=Salford; O=COMODO CA Limited; CN=COMODO RSA Domain Validation Secure Server CA
* SSL certificate verify ok.
> PUT /collections/xxxxxxxxxxxxxxxxxxxxxxxxxx HTTP/1.1
> Host: api.getpostman.com
> User-Agent: curl/7.54.0
> Accept: */*
> content-type: application/json
> x-api-key: xxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Content-Length: 558749
> Expect: 100-continue
>
< HTTP/1.1 100 Continue
* We are completely uploaded and fine
< HTTP/1.1 500 Internal Server Error
< Access-Control-Allow-Credentials:
< Access-Control-Allow-Headers:
< Access-Control-Allow-Methods:
< Access-Control-Allow-Origin:
< Access-Control-Expose-Headers:
< Content-Type: application/json; charset=utf-8
< Date: Wed, 14 Feb 2018 08:17:10 GMT
< ETag: xxxxxxxxxxxxxxxx
< Server: nginx
< Vary: Accept-Encoding
< X-RateLimit-Limit: 60
< X-RateLimit-Remaining: 56
< X-RateLimit-Reset: 1518596176
< Content-Length: 82
< Connection: keep-alive
<
* Connection #0 to host api.getpostman.com left intact
{"error":{"name":"serverError","message":"Something went wrong with the server."}}
real 1m51.701s
user 0m0.041s
sys 0m0.013s
sfncook
(Shawn Cook)
October 26, 2019, 5:43pm
4
@kunagpal You clearly did not read his question.
lginoux
(Loïc Ginoux)
December 5, 2019, 3:41pm
5
The 500 error on collection update endpoint is still not fixed, it seems. I have the same issue How to update an api via a json import?