ssossossosso

Forums

Covering OroCRM topics, including community updates and company announcements.  Subscribe

Forums OroCRM OroCRM – Programming Questions Add tags via API

This topic contains 3 replies, has 3 voices, and was last updated by  roberto.taschetto 2 months, 3 weeks ago.

  • Creator
    Topic
  • #53801

    kelton23om
    Participant

    Hi guys,

    I want to add some tags via Account or contact API (Post/Put).
    The handler seems to be able to support that. But i didn’t found how to write the JSON correctly.

    So, is it already implemented ? or should i extends handler ?

    thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Author
    Replies
  • #53802

    Alexandr Smaga
    Participant

    Hello @kelton23om !

    POST and PUT requests usually processed through the same form and “save handler” as the UI requests. So basically it’s possible to create/assign tags via API call, but format for the passed data is not well designed for this purposes, because you have to pass all existing assigned tags back as well.

    Here is an example of request that creates new tag assign one own tag and one tag that is not owned by current user

    #53803

    kelton23om
    Participant

    hi!

    thanks for your answer,

    I tried your solution and indeed it works with js call (with Form Data)
    But i can’t insert a tag by using the api Sanbox, or by using Guzzle (with json content).

    I wrote the JSON in different ways, but i never could insert tag.

    Any idea ??

    #53804

    roberto.taschetto
    Participant

    Hi @kelton23om,

    did you find any solution for this?

    Thank you in advance,
    Roberto

Viewing 3 replies - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.

ssossossosso