Announcement

Collapse
No announcement yet.

Java API PUT request

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Java API PUT request

    Hi!

    In the Java client API documentation (https://docs.espocrm.com/development/api-client-java) there is only a GET request example.

    Can somebody please help me with a PUT request.

    I tried it, but I always get a RequestException (Not Found):

    My code:

    Code:
    EspoApiClient client = new ClientBuilder()
      .setHost({url})
      .setApiKey({api-key})
      .build();
    
    String payload = "{firstName : 'test', lastName : 'test'}";
    client.request(Method.PUT, "Contact/{id}", payload);
    I would really appreciate some help!

    Thanks in advance,
    Stefan

    EDIT: Nevermind. Found another solution
    Last edited by Stefan; 12-13-2021, 09:12 AM.
Working...
X