So my problem is, i have 2 instances of jira in diferent locations and i want to request a service, via Jira REST Api, from one of the instances to the other. At the service, that is on Jira v7.2.12, i need to get the body content from the request but the question is how?
How can i do it with Jira REST Api? Is it possible to do it?
Regards.
Hello António,
I am not completely sure I understand your question. If you want to call REST API of Jira instance, it doesn't matter whether you are calling it from another Jira or some app on your computer. You will have to authorize the request the same way (e.g. through Basic Auth).
If you are interested in a way how to do it (how to call API) - it generally depends on your use case. You can either write yourself one-time script to be executed e.g. from ScriptRunner plugin or you can write yourself a plugin which will make use of some REST Client as Unirest or Apache HTTP Client.
Regards,
Martin
Hi Martin,
I was able to solve my problem, passing to @Consumes annotation on the method, the MediaType.APPLICATION_FORM_URLENCODED attribute, and on the method parameters, the @FormParam annotation from JAX-RS with the string name that is associated to the request body from the client.
Was a problem of not knowing what was the mediatype that the client was passing throw the request body.
Thanks for the response anyway .
Regards,
António
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.