<div dir="ltr">I have been able modify the default behavior of swagger-codegen to produce bindings that use relative URLs to identify resources. The required changes can be seen here[0]. The compiled jar is available for download here[1]. <br><br>The following command can be used to generate python bindings. Replace 'python' with 'ruby' and you'll get ruby bindings. The json file is the API schema returned by the Pulp server at <a class="external" href="http://localhost:8000/api/v3/docs/api.json">http://localhost:8000/api/v3/docs/api.json</a>. <br><br>java -jar ./swagger-codegen-cli.jar generate -i ~/Downloads/pulp3-api.json -l python -o some_directory_name<br><br>[0] <a href="https://github.com/dkliban/swagger-codegen/commit/e31e96769864b73b06bd99f5e20e4720562539b9">https://github.com/dkliban/swagger-codegen/commit/e31e96769864b73b06bd99f5e20e4720562539b9</a><br>[1] <a href="https://repos.fedorapeople.org/pulp/pulp/swagger/swagger-codegen-cli.jar">https://repos.fedorapeople.org/pulp/pulp/swagger/swagger-codegen-cli.jar</a><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, May 1, 2018 at 11:18 AM, David Davis <span dir="ltr"><<a href="mailto:daviddavis@redhat.com" target="_blank">daviddavis@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">We’ve exposed IDs and I think the next goal will be to somehow let Katello use these IDs. I’ve opened a new story to solicit feedback on how this’ll work:<div><br></div><div><a href="https://pulp.plan.io/issues/3636" target="_blank">https://pulp.plan.io/issues/<wbr>3636</a><span class="HOEnZb"><font color="#888888"><br></font></span></div></div><div class="gmail_extra"><span class="HOEnZb"><font color="#888888"><br clear="all"><div><div class="m_-4971748094304000821gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><br></div><div>David<br></div></div></div></div></div></div></div></div>
<br></font></span><div class="gmail_quote"><div><div class="h5">On Tue, May 1, 2018 at 9:14 AM, Brian Bouterse <span dir="ltr"><<a href="mailto:bbouters@redhat.com" target="_blank">bbouters@redhat.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote"><span>On Tue, May 1, 2018 at 7:59 AM, Bryan Kearney <span dir="ltr"><<a href="mailto:bkearney@redhat.com" target="_blank">bkearney@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On 04/30/2018 04:08 PM, Brian Bouterse wrote:<br>
> @asmacdo, checking in on the why is great. I want to try to articulate<br>
> the benefits as I see them. Other perspectives and discussion are welcome.<br>
> <br>
> The design of using URLs for referring things is a design whose goal is<br>
> to minimize complexity as the # of resources grows. The Internet is a<br>
> useful analogy here. When someone wants to tell me how to find something<br>
> on Instagram, if the article's name is 'cat_pic432642' and that's all I<br>
> know, I'm going to have a hard time figuring out the actual URL to ask<br>
> Instagram's servers for, e.g. /thepostsarehere/cat_pic432642<wbr>. Even if I<br>
> did know how Instram's url space was laid out, I have to think about it<br>
> different from all other web services I interact with; now they're all<br>
> different. This is the power of the URL itself. All clients and all<br>
> servers can use the uniform resource locator to refer to things. I think<br>
> this was the main contribution from Tim Berners-Lee that allowed him to<br>
> implement HTTP which has URIs at its heart.<br>
<br>
</span>But, to Austins Point, if folks are going to interact with Pulp either<br>
from the cli or from Go|rust|python libraries, they will not see the<br>
urls. In your analogy, you would most likely google cat_pic432642  and<br>
never know the url you are going to.<br></blockquote></span><div><br>I agree there will be much binding-based usage, and CLI usage, but there
 will always be users who will use httpie with some bash scripting calls
 instead. So from that perspective, the goals remain the same they have for years; we need to put forth 
the best, lowest-complexity REST API.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<span class="m_-4971748094304000821m_4138795520150130818HOEnZb"><font color="#888888"><br>
-- bk<br>
<br>
</font></span></blockquote></div><br></div></div>
<br></div></div><span class="">______________________________<wbr>_________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com" target="_blank">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/mailman<wbr>/listinfo/pulp-dev</a><br>
<br></span></blockquote></div><br></div>
<br>______________________________<wbr>_________________<br>
Pulp-dev mailing list<br>
<a href="mailto:Pulp-dev@redhat.com">Pulp-dev@redhat.com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/pulp-dev" rel="noreferrer" target="_blank">https://www.redhat.com/<wbr>mailman/listinfo/pulp-dev</a><br>
<br></blockquote></div><br></div>