API Days - Paris

I travelled to Paris the day before the conference with Matt and we got to the Hotel in the evening, later than expected as we’d not considered traffic when getting a taxi in to Paris from the airport, I think next time I’d probably take the train in. We then met up with Tom and found a local restaurant/bar to have dinner.

As the API Days conference started at 1 o’clock the next day and I was up early I was able to do a bit of sight-seeing before heading back to the hotel to get on with some work and make sure I was ready for my session later that day. I had breakfast and headed out on the metro across Paris to the Eifel tower.

There was a light covering of snow everywhere and it was still very cold and there was more snow coming down as I emerged from the metro, although it didn’t really show in the pictures and it was still well before sunrise so everything was quite dark. I grabbed a coffee at one of the nearby cafes and caught up on Slack.

After coffee it had brightened up a bit but was still nice and snowy all around so I walked down closer to the Eifel Tower and a little way along the Seine before heading back across to the Arc De Triomphe and back on the metro back to the hotel. I then made my way over to the Cité des Sciences et de l’Industrie where the conference was to be held. I met Tom as I left the metro station and we headed into the venue together to find the booth and meet the rest of the team.

My workshop “Applying AI to API Testing across the lifecycle” was early in the conference, starting just 30 minutes after the doors opened so I went to get set up fairly early to find that the projector in the room wasn’t working but it turned out I’d gone to the wrong room and over in the room I was in everything worked properly. My talk went well and I had some good questions from the audience at the end and was glad to have it done so I could enjoy the remainder of the conference. I spent most of the rest of the day at or around the booth meeting people; discussing API Connect with them; giving demos and guiding them through the sign up for our free 30 day trial.

In the evening of the first day of the conference there was a Speaker Soiree which a few of us headed to after dropping things back to the hotel, it was at Belushi’s on the Canal de l’Ourcq so was just a short walk from my hotel. Given the size of the conference and the number of tracks going on the event was packed with those speaking at the event and was a great oppportunity to meet some of the others and share our experiences in the API space. As the world cup game between France and Morocco was on that evening we’d been warned to expect trouble in the streets of Paris, so headed back to the hotel just after half time to avoid anything that kicked off after the match. Later on from the hotel I could hear that France had won with the jubilant sounds of car horns.

The other thing we had at the booth which was a different idea from the previous time was a series of SmartTalks - 10 minute slots scheduled throughout the event with different people giving a taster session on a topic. I had two on the schedule - “API Deployment automation with IBM API Connect and GitHub Actions” and “Lambda integration in IBM API Connect on AWS”. As we were situated by one of the coffee stations we also had a steady stream of people passing our booth so the opportunity to sit down with a coffee and listen to a short talk definitely appealed. These seemed to work really well and drew an audience, often leading to interesting one to one follow on conversations with a few of the attendees.

Invoke IBM Cloud Functions from API Connect

Cloud functions offer an easy way to build functionality and only pay for the time they are actually running without having to worry about how it will be hosted - you just right the code, save it and it is ready to be invoked. The function can be invoked through an event trigger or as a REST API - in this case I’m going to show how you can trigger a function as part of your API Connect assembly flow - providing an easy way to manage and socialise the functionality you have built.

To call an IBM Cloud function you first need to exchange your IBM Cloud API Key for an IAM access key using the IAM Authentication API.

This is a case of setting up and sending a post request to IBM Cloud IAM, to do this I used a set-variable policy to configure the headers and body followed by an invoke to https://iam.cloud.ibm.com/identity/token. The set-variable looks like this:

      - set-variable:
          version: 2.0.0
          title: setup iam request
          actions:
            - set: message.headers.content-type
              value: application/x-www-form-urlencoded
              type: string
            - set: message.headers.accept
              value: application/json
              type: string
            - set: message.body
              type: string
              value: >-
                grant_type=urn:ibm:params:oauth:grant-type:apikey&apikey=$(iam-apikey)​                

Once you have this access key you can use this to call your function using the endpoint provided in the UI:

{

For the authentication to the function URL we need to set the Authorization header to Bearer {access_key} where access_key is from the body of the previous request, so to obtain this we can use a Parse policy to parse the returned json, and then another set-variable policy to configure the headers for the Function invoke. This time the set-variable looks like this:

      - set-variable:
          version: 2.0.0
          title: setup function call
          actions:
            - set: message.headers.authorization
              value: Bearer $(iam.body.access_token)
              type: string
            - set: message.body
              value: $(request.body)
              type: any
            - set: message.headers.accept
              value: application/json
              type: string

As you can see we’re setting the authorization and accept headers, and passing the original request body from the inbound request. We follow this with an invoke of the function URL and a map, because the JSON returned from the function API includes details on invocation as well as the defined response:

{

The end to end flow looks like this:

{

Here is the complete sample swagger file which can be used in any API Connect deployment, including our new API Connect service on AWS

2002 - Wedding
2002 - Wedding
2003 - Malta
2003 - Malta
2004 - Iguazu
2004 - Iguazu
2005 - Greece
2005 - Greece
2006 - Abi
2006 - Abi
2007 - Cornwall
2007 - Cornwall
2008 - Malta
2008 - Malta
2009 - Jessica
2009 - Jessica
2010 - Portsmouth
2010 - Portsmouth
2011 - Torquay
2011 - Torquay
2012 - Olympics
2012 - Olympics
2013 - New Year's Eve
2013 - New Year's Eve
2014 - London
2014 - London
2015 - Majorca
2015 - Majorca
2016 - Valencia
2016 - Valencia
2017 - Nice
2017 - Nice
2018 - Lake Garda
2018 - Lake Garda
2019 - Switzerland
2019 - Switzerland
2020 - Gosport
2020 - Gosport
2021 - New Forest
2021 - New Forest
2022 - Costa Rica
2022 - Costa Rica

New York

The next morning I was up early and decided to head first to the High Line - a park/walkway created from an historic raised rail line which goes along the West Side of Manhatten. It’s fantastic to see the way the plants have been selected and seeing trees growing in between the old tracks with different sections having distinct settings from wild prairy to wooded sections providing a relaxed park atmosphere with a unique historic character to it. At the end of the line I headed to the Starbucks Reserve coffee roastery to have a coffee before heading back. I then went back to my hotel and got changed for the warmer day ahead and headed down to the dock for my boat tour. The boat tour took me right out past the Statue of Liberty with great views across the skyline along the way. I then checked out the Drama bookshop and then took the subway up to Central Park where I sat in the park to have my lunch. World Trade Center Then in the evening I went to Hudson Yards which is a really interesting development built over the top of railway yards, making use of land that couldn’t previously be used. There’s some really innovative sustainability steps been taken in how water and energy are managed and growing trees in shallow soil encouraging their routes to grow horizontally for stability and nutrients.

Hudson Yards - Sustainability Animation from Neoscape on Vimeo.

I then went up to The Edge where you get stunning views across the city. The next day was the AWS Summit which was the reason I was in town. This was a massive event and hugely popular, resulting in long queues for attendees to get in snaking across the entrance foyer and around the block. Fortunately being there as an exhibitor I'd been able to arrive early and prepare before the main entrance opened. IBM had a large booth with 4 demo screens and most of the day I spent here meeting people and talking about our new API Connect on AWS SaaS offering. I also got time to explore the other exhibitors and talk to some of the AWS team which was really interesting and useful. In the evening we had an IBM Client appreciation reception at the classic car club where I met more people and chatted with them surrounded by the impressive car whilst watching the sun go down over the Hudson until it was time for me to head to the airport for my flight home.

In the afternoon Laura and I did a ‘garden to glass’ experience at the Hotel, just the two of us, where Diego took us first around the gardens of the hotel to see their sustainability at work and the different plants they grow and how they can be used. We took a basket around with us and gathered lots of sprigs of herbs, flowers and even wild blackberries.

In the gardens we also met Floriana who oversees the gardens at the Belmar who we talked to about natural pest control and composting.

When we got back to the bar, we laid out all the ingredients on a table and Diego showed us how to make a coffee rum cocktail from rum which he’d left coffee beans soaking in earlier - very simple but delicious!

We then got to make our own cocktail from some of the items we’d gathered from the garden - first selecting the spirit and then crushing the leaves together with a caramelised orange segment. We then added these to a shaker with Guaro, syrup and ice and shook it. Diego smoked the glasses on a pine smoker, added ice and then we poured the cocktails in and garnished with more findings from the garden - in this case some flower petals and a carrot leaf.

For the last cocktail we learnt how to garnish the rim of the glass and then could sit back and watch the expert at work in making the cocktails for us with cucumber and basil from the garden.