SlideShare ist ein Scribd-Unternehmen logo
1 von 85
BP204 Take a REST and put your data
                    to work with APIs
                    Craig Schumann | Inner Ring Solutions




© 2013 IBM Corporation
Agenda

       Background

       Practical Examples from real life

       Designing guidelines for creating your own APIs

       How to create your own APIs and free your data




2         © 2013 IBM Corporation
House keeping

 IBM Lotus Domino®

 IBM Domino®

 IBM Lotus Notes®

 IBM Notes®

 IBM Lotus Designer®

 IBM Designer®




3
4
So much data….

 What this talk is about is freeing your data




5
Public data….

 What this talk is about is freeing your data




6
Enterprise data….

 What this talk is about is freeing your data




7
Bring it together…

 What this talk is about is freeing your data




8
All in one app

 What this talk is about is freeing your data




9
How about sharing?

 What this talk is about is freeing your data




10
What are APIs

    APIs are a way to get access to data and functionality of your application without
     providing UI.
    They can be implemented in almost every way imaginable
       ─ Android apps use public java packages, etc.
       ─ Developing an iOS application, you use the iOS API via C header files.
       ─ Web applications also have APIs in the form of Web services, or even just URLS. A
         permalink is a form of web API.



 Bottom line - An API makes it easier for other people or
  applications to access your data or features.




11     © 2013 IBM Corporation
What are APIs

    APIs have been around a long time, and it gives others access to your system via
     a public, documented interface.
    Provides public paths to into more proprietary systems.
      -     WIN32
      -     Notes BE Objects
      -     NotesCAPI
      -     iOS, Android
    They give you the ability to create new applications on top of existing data /
     platforms.


 This is not to hide all your secret sauce (though it could be)! It is more to keep things
   simple for your users. To give people access to the good stuff without burdening
   them with the details of how the back end works.


12        © 2013 IBM Corporation
What is a WEB API?

A web API is nothing more that an API (access to your stuff) that people use over
 HTTP - AKA web services

Yesterday when you talked about web services, you were talking about SOAP
 Simple Object access protocol.



Today the trend these days is to build web services around REST (REpresentational
 State Transfer). REST is literally what the wide web is based on.




13
Web Applications with public APIs

 Tell people what you had for lunch or the product you are about to launch:
     – Connections / Facebook / Twitter (https://dev.twitter.com/docs/api)

 Show your sales for the month:
     – Google Charts (https://developers.google.com/chart/)

 Send a text message from your web app
     – Twillio (http://www.twilio.com/docs/api/rest)

 Find pictures for your presentation?
     – Flickr (http://www.flickr.com/services/api/)

 Blog about your new product
     – WordPress.com REST API (http://developer.wordpress.com/docs/api/)

 Netflix
     – Pick a movie to watch now your app is launched! (http://developer.netflix.com/docs)


14     © 2013 IBM Corporation
Why create an API?

 Break apart your application and the data.

By providing an API:
     – You don't have to expose the nitty-gritty of how your app stores data.
     – You create a common way to access your data.
     – APIs force you to separate your client related code from your data related code. Then by
       doing this, anyone can create a client. And the client can be anything - mobile, desktop,
       web, native, anything.
     – If you are thinking about creating mobile versions of your applications, having an API to
       access the data will be huge.




15
Why create an API?

 Don't get caught in the idea that XPages are the only way to access Domino data.
  API access to your data can free you from a lot of constraints.
 A simple document focused API for example will make it easy to create any sort of
  mobile app you want. Want to create native iOS app? Great! Want to create a
  mobile web app? Fantastic! Do you need a desktop application? Right on! In all
  these cases, the server side has not changed at all. Your client app is merely a
  wrapper around your API!




16
17
Example - Performance

So lets say I have a web page with this
Embedded in page
Embedded in page




20
Working with data

How about this?
22
Working with data

 Start with a basic Notes view in XPages

 Add an onclick event that ties into a client side JavaScript event




23
Working with data

 Start with a basic Notes view in XPages

 Add an onclick event that ties into a client side JavaScript event
     <xp:viewPanel var="rowData" rows="10" id="viewPanel1"
     viewStyleClass="viewPanel" rowClasses="viewPanelRow">
        <xp:this.facets>
               <xp:pager partialRefresh="true" layout="Previous Group Next"
                          xp:key="headerPager" id="pager1" for="viewPanel1">
               </xp:pager>
        </xp:this.facets>
        <xp:this.data>
               <xp:dominoView var="view1"
                          databaseName="ls13irsbikes_inventory.nsf" viewName="demoView">
               </xp:dominoView>
        </xp:this.data>
        <xp:this.rowAttrs>
               <xp:attr
                   value="javascript:loadDocument('#{javascript:rowData.getUniversalID()}')"
                   name="onclick">
               </xp:attr>
        </xp:this.rowAttrs>
     [……]
     </xp:viewPanel>




24
Working with data

 The onclick event then triggers 3 things to happen
      – The full document is fetched in JSON format
      – One of the Google charts is updated with the sales for that brand of bike
      – Flickr is searched for images tagged with the brand and model of bike selected


     function loadDocument(unid){
         // get the document we have selected
         getNotesDocument( unid, "ls13/irsbikes_inventory.nsf", function(doc){
              // get related flickr images
              flickerAPIImages(doc.getItem("brand")+","+doc.getItem("model"));
              // update sales data
              googleChartsAPI(doc.getItem("brand"));
         })
     }




25
Working with data

      Step one is to get the document…

      Domino can do this for you, but it’s
       better to have a little more control
       over what you get.



     function getNotesDocument( docid, db, callback ){
         var url = './apiv1.xsp?f=document';
         url += "&db=" + db;
         url += "&documentId=" + docid;
         $.getJSON(url,function(data){
             var doc = new NotesDocument(data);
             callback(doc);
         });
     }



26
Working with data
      When you control the API, you control the data and how it is
       represented.



     function getDocument(){
         var db:NotesDatabase = session.getDatabase("", param['db']);
         var doc:NotesDocument = db.getDocumentByUNID(param['documentId']);

         try{
           var docXML = doc.generateXML();
           var writer = facesContext.getResponseWriter();
           var excon = facesContext.getExternalContext();
           excon.getResponse().setContentType("application/json");
           writer.write( org.json.XML.toJSONObject(docXML).toString());
         }
         catch(e){
             print(e.toString())
         }
     }




27
Working with data

      The chart is updated with an API call
       to get the data needed
      The chart is drawn with the Google
       charts engine using the data that is
       returned

     function googleChartsAPI(brand){
         var url = "./apiv1.xsp?f=sales&k=months";
         if( null != brand && "" != brand ){
             url += "&brand=" + brand;
         }

          $.getJSON(url, function(d) {
            [Google charts code]
          })

     }


28
Working with data

 The flicker search is done the same way.




29
Working with data

 The flicker search is done the same way…
     function flickerAPIImages(search){
     /*
      * Flickr Photo API
      * http://www.flickr.com/services/api/flickr.photos.search.html
      */

         search = search.replace(/,/g,"+");
         //
         var URL = "http://api.flickr.com/services/rest/?method=flickr.photos.search";
         url += "&api_key=<your api key goes here>";
         url += "&tags=cycling%2C+mountain&text="+search+"+%20bikes";
         url += "&per_page=5&format=json&nojsoncallback=1";
         $.getJSON( URL, function(d) {
                var source   = $("#entry-template").html();
                var template = Handlebars.compile(source);
                var context = d.photos;
                var html    = template(context);
                $('#imageInner').html(html);
         })
     }




30
Working with data

 XPages - server side is not the place to do it
    – Rendering a page should not wait for a response from some other site.
    – Things get messy quick with a mix of server side and client side code updating
      the page

 In general don't fill your page with tons of data
    – Valuable data is trapped and mixed in with the rest of the UI
    – There is a lot of different kinds of data here, from multiple sources.

 Partial refresh is not always the answer either.
    – Hard to chain things together so one value affects many others
    – could render the whole page
Data trapped in the UI???

 What happens when the client isn’t always a browser?

 Other clients might not want HTML



 Example - XSnippets




32
Example - XSnippets

 XSnippets – OpenNTF.org project
     – http://openntf.org/XSnippets.nsf/home.xsp
     – Template can be downloaded and customized at http://xsnippets.openntf.org/


 Currently there is only a web interface




33
XSnippets – browser client




                             That is enough
                                 Right?




34
XSnippets API




35
XSnippets – Designer client!




36
37
Options

    SOAP
      ─   ‘Classic’ Web services, Strong "object model"
      ─   Message based / transactional
      ─   Hard to do simple things like getting a list of things
      ─   been there done that....
    REST
      ─ resources / Object model based
      ─ resources can be anything you can create a URI for.
      ─ path oriented
          ─ database/collection (like a view)
          ─ database/collection/entity (like a document)




38    © 2013 IBM Corporation
REST

REST is not a standard. REST is a style, a way to build a web application.

That being said, REST does make use of standards. HTTP, XML, URLs

REST works with resources as collections and objects. A resource can be anything
 you are interested in. For example:

www.example.com/customers/IBM

Would be a request for the IBM customer resource. A web server can respond with a
 representation of the resource IBM.html for example, an XPage customer.xsp, or
 just an XML or JSON document with the IBM specific data.



Notice there is no “VERB” in the resource URI….




39   © 2013 IBM Corporation
REST and URLs

The key difference with a RESTfull service and a SOAP service is the way you use
 the HTTP verbs.

SOAP encourages the method to define the verb - getCustomers.

REST uses the HTTP methods* to define the operation

            GET /customers




* http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html



40   © 2013 IBM Corporation
REST - GET

You have probably head about HTTP GET. GET is the most basic action a client can
 do. With GET the client is requesting a read only copy of a resource.




41   © 2013 IBM Corporation
REST - POST

 You are also probably familiar with POST. This the most common thing to do when
  sending data back to the server - submitting a form for example.
 POST is should be used when creating or updating resources when the resulting
  URI is not known.
 RESTfull services will also make use of PUT and DELETE, and this is where a true
  RESTfull service will diverge a bit from the common use of POST.




42   © 2013 IBM Corporation
REST - PUT

 PUT is used when you are updating an existing resource.
     – PUT is used when you know the path to the resource.
     – PUT can create resources if one does not already exist



 POST vs PUT
     – POST in form submission because you don’t know what the URL to the new resource is
       going to be.
     – PUT requires the URL to resource to be known
     – HTML FORMs only support GET and POST




43     © 2013 IBM Corporation
REST - DELETE

DELETE does what it says on the tin - deletes a resource.




44   © 2013 IBM Corporation
REST verbs

 Client side JavaScript with Dojo
     dojo.xhrPut ({
         url: '/api_v1.xsp',
         putData: ‘data to send to server',
         handleAs: ‘text’,
         error: function(result) {
            // Whoops
          }
     });
 Java
     URL url;
     try {
        url = new URL(uri);
        HttpsURLConnection conn = (HttpsURLConnection)url.openConnection();
        conn.setDoInput(true);
        conn.setDoOutput(true);
        conn.setRequestMethod(“PUT");
     }

45
REST verbs – XPages example
     <?xml version="1.0" encoding="UTF-8"?>
     <xp:view xmlns:xp="http://www.ibm.com/xsp/core" rendered='false'>

      <xp:this.afterRenderResponse><![CDATA[#{javascript:

             var request = facesContext.getExternalContext().getRequest();
             var writer = facesContext.getResponseWriter();

             var method = request.getMethod();
             if( method === "GET" ){
                writer.write("You did a "GET"");
             }
             else if( method === "POST" ){
                writer.write("You did a "POST"");
             }
             else if( method === "PUT" ){
                writer.write("You did a "PUT"");
             }
             else if( method === "DELETE" ){
                writer.write("You did a "DELETE"");
             }

       }]]></xp:this.afterRenderResponse>

     </xp:view>

46
REST verbs – XPages example




47
REST verbs – XPages example

 DEV-HTTP-CLIENT (Chrome App) http://bit.ly/Wj8U67




48
REST - resources

    REST uses HTTP to provide the VERB to the resource
    Since the verb (get,post,etc) is part of the request, you shouldn't use verbs in the
     URL to the resource, only nouns.
    If your data has Objects like customers, projects, meetings, etc. the REST API
     should use the same object names



                                   www.example.com/customers?id=IBM

                                                  vs

                                www.example.com/getCustomer?customer=IBM




49     © 2013 IBM Corporation
REST

URLs should point to logical resources, not physical.

                                www.example.com/customers/IBM

                                              vs

                              www.example.com/customers/IBM.html



                                       These kinds of URLs are not easy in
                                       Domino. Luckily REST is a design
                                       principle, and not a standard!
                                       You can still design a RESTfull api with
                                       Domino.




50   © 2013 IBM Corporation
RESTful data

 RESTful APIs typically don't deal in HTML. HTML is UI, Your REST API shouldn't be
  worrying about or injecting UI
    Don’t include HTML in your RESTful data
    Strictly speaking, the format for data can be anything, but it’s usually:
           XML
           JSON/JSONP (AKA XML with curly braces).




51        © 2013 IBM Corporation
REST and errors

 Use error codes in the response
     ─ 2xx == all good
     ─ 4xx == client messed something up
     ─ 5xx == server messed something up




52   © 2013 IBM Corporation
RESTful errors




53   © 2013 IBM Corporation
API Versioning

You must version your API!
 Versioning your API means that you don't need to update all your clients
 immediately, if at all, when you add or change your API**.

     Make the version part of the resource, not a parameter. Make it explicit.

                                 www.example.com/v1/customers/IBM

                                                   vs

                                 www.example.com/customers/IBM?v=1




**You will change it, so just get it out of the way and design it into V1


54      © 2013 IBM Corporation
API Versioning




55   © 2013 IBM Corporation
API Authentication

 A RESTfull application should also be stateless. So this means that you should not
   be storing session information server side. This is Domino so you don't have much
   control over this, but in general you shouldn't be using appScope or sessionScope
   variables to store anything.
    Public / No authorization needed
    HTTP Authentication
      ─ Server handles the login
      ─ All HTTP requests must contain the login info via Authorization header
      ─ Database ACL is set to require authentication (Anonymous=No Access)
    Token Authentication
      ─ You handle the login
      ─ an API key is generated for client access. That key is used as the login credentials. Not
        really security, but limits access to the data to a known set of users and gives
        application control over who has access without having to manage the ACL
      ─ Database ACL is more open

56    © 2013 IBM Corporation
57
Old school

 &ReadViewEntries

 Supported since R6

 Gives you a dump of a view in XML or JSON format

      Pros                                       Cons
        – Built in so performance is good          – No control over the output
        – No coding needed                         – Does not support JSONP
        – XML is a little more useful than the     – There are a few bugs that can cause
          JSON version                               the JSON output to be invalid
                                                   – There is no equiv for docs so
                                                     everything you need must be in the
                                                     view
                                                   – Not really an API..




58
Old School

 demoView?readviewentries




59
Old School

 demoView?readviewentries&outputformat=json




60
POA (Plain old Agents)

 These don’t require anything special and can do all the same things we talked
  about previously.
 Can use Java or LotusScript.




61
POA (Plain old Agents)
     Sub Initialize
         Dim s As New NotesSession

         Dim db As New NotesDatabase("", "ls13/irsbikes_inventory.nsf")

         Dim docs As NotesDocumentCollection
         Set docs = db.AllDocuments
         Dim d As NotesDocument
         Set d = docs.getfirstdocument
         Print "Content-Type:application/xml"
         Print |<?xml version="1.0" encoding="UTF-8"?>|
         Print |<bikes>|
         while Not d Is Nothing
              Print "<bike>"
              Print "<brand>" + d.brand(0) + "</brand>"
              Print "<model>" + d.model(0) + "</model>"
              Print "</bike>"
              Set d = docs.Getnextdocument(d)
         Wend
         Print |</bikes>|
     End Sub




62
POA (Plain old Agents)




63
POA (Plain old Agents)
     public class JavaAgent extends AgentBase {

          public void NotesMain() {

             try {
                 Session session = getSession();
                 AgentContext agentContext = session.getAgentContext();

                 Database db = session.getDatabase("", "ls13/irsbikes_inventory.nsf");
                 DocumentCollection docs = db.getAllDocuments();
                 Document doc = docs.getFirstDocument();

                 java.io.Writer sw = new java.io.StringWriter();
                 PrintWriter ao = getAgentOutput();
                 ao.println("Content-type: text/xml");
                 ao.println("<bikes>");
                 while(null!=doc){
                    // write the document out
                    doc.generateXML(sw);
                    doc = docs.getNextDocument(doc);
                 }
                 sw.flush();
                 ao.print(sw.toString());
                 ao.println("</bikes>");

             } catch(Exception e) {
                 e.printStackTrace();
              }
         }
     }

64
Domino and REST

 Introduced in 8.5.3



 4 built in options
     – Domino Data Service
     – XPages REST Services Control
     – Custom Database Servlet
     – Custom Wink Servlet




65
Domino and REST

 Pros                                           Cons
     – Built in so support and performance is     – DDS Needs to be enabled on the
       good                                         server (admins need to be involved)
     – No coding needed                           – Very granular – database, view
     – Very granular                                properties
                                                  – URLs are not app specific. This is
                                                    Domino’s API = views and documents
                                                  – No coding – can’t really expose logical
                                                    application objects
                                                  – Not documented very well (yet)




66
Domino and REST – Domino Data Services




67
Domino and REST




68
Domino and REST – Domino Data Services




69
Domino and REST – Domino Data Services
      http://{host}/api/data
     [

         {

              "@title":"Activity Trends (MADER)",

              "@filepath":"activity.nsf",

              "@replicaid":"852578220B751506",

              "@template":"StdActivityTrendsDatabase",

              "@href":"http://localhost:80/activity.nsf/API/data/collections"

         },

         {

              "@title":"Administration Requests",

              "@filepath":"admin4.nsf",

              "@replicaid":"8525782203751506",

              "@template":"StdR4AdminRequests",

              "@href":"http://localhost:80/admin4.nsf/API/data/collections"

         },

         ……

     ]




70
Domino and REST – Domino Data Services
      http://{host}/{path}/api/data/collections
     [

         {

              "@title":"By Type",

              "@folder":false,

              "@private":false,

              "@modified":"2012-12-19T20:27:13Z",

              "@unid":"0AC52D85954AB7E785257AD9005D6E35",

              "@href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/collections/unid/0AC52D85954AB7E785257AD9005D6E35"

         },

         {

              "@title":"By Size",

              "@folder":false,

              "@private":false,

              "@modified":"2012-12-19T20:27:13Z",

              "@unid":"66ED263FEEC2CF7485257AD9005D3342",

              "@href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/collections/unid/66ED263FEEC2CF7485257AD9005D3342"

         }, ……

     ]




71
Domino and REST – Domino Data Services
      http://{host}/{path}/api/data/collections/name/{view name}
      http://{host}/{path}/api/data/collections/unid/{view unid}

     [

         {

              "@href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/collections/name/demoView/unid/6783AB7D38FACE2A85257AD9005BDC35",

              "@link":

              {

                   "rel":"document",

                   "href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/documents/unid/6783AB7D38FACE2A85257AD9005BDC35"

              },

              "@entryid":"1-6783AB7D38FACE2A85257AD9005BDC35",

              "@unid":"6783AB7D38FACE2A85257AD9005BDC35",

              "@noteid":"906",

              "@position":"1",

              "@siblings":22,

              "@form":"inventory",

              ….

         },

     …..

     ]

72
Domino and REST – REST Services Control

 The REST Services Custom Control comes with the Extension Library.

 No Coding!

 Add to an XPage and set the ‘pathInfo’ paramter.

 Different types of resources can be retrieved
     – databaseCollectionJsonService - Read the list of databases on the server.
     – viewCollectionJsonService - Read the list of views and folders in a database.
     – viewJsonService - Read the entries in a view or folder.
     – documentJsonService - Create, read, update and delete documents.

 Adds to the path for the XPage for specific resources




73
Domino and REST – REST Services Control




74
Domino and REST – REST Services Control




75
Domino and REST – REST Services Control
     http://localhost/ls13/irsbikes_web.nsf/restControl.xsp/bikes




76
Domino and REST – Domino Data Services


 More on OpenNTF
     – Niklas Heidloff - http://www.openntf.org/blogs/openntf.nsf/d6plinks/NHEF-8JGGPE
         • Documentation
         • Examples
         • Video




77
“XAgents”

 XPages with rendered=‘false’

 Can write your API in Java or Server Side JavaScript

 Keeps you in the same frame of mind as the rest of your XPages development.




78
“XAgents”

     <?xml version="1.0" encoding="UTF-8"?>
     <xp:view xmlns:xp="http://www.ibm.com/xsp/core" rendered='false'>

     <xp:this.afterRenderResponse><![CDATA[#{javascript:
         var externalContext = facesContext.getExternalContext();
         var response = externalContext.getResponse();
         var request = externalContext.getRequest();

         if( !param.containsKey("p") ){
           response.setStatus(400);
           response.setContentType("application/json");
           var writer = facesContext.getResponseWriter();
           writer.write("{ "code":400, "text":"Bad Parameter",
           "message":"Missing method call parameter 'p'" }");
           return;
         }

         var s = new org.openntf.api.snippet();
         s.service( request, response);
     }]]>
     </xp:this.afterRenderResponse>
     </xp:view>



79
“Xagents” + JAVA = Happy

     <?xml version="1.0" encoding="UTF-8"?>
     <xp:view xmlns:xp="http://www.ibm.com/xsp/core" rendered='false'>

     <xp:this.afterRenderResponse><![CDATA[#{javascript:
         var externalContext = facesContext.getExternalContext();
         var response = externalContext.getResponse();
         var request = externalContext.getRequest();

         if( !param.containsKey("p") ){
           response.setStatus(400);
           response.setContentType("application/json");
           var writer = facesContext.getResponseWriter();
           writer.write("{ "code":400, "text":"Bad Parameter",
                     "message":"Missing method call parameter
         'p'" }");
           return;
         }

         var s = new org.openntf.api.snippet();
         s.service( request, response);
     }]]>
     </xp:this.afterRenderResponse>
     </xp:view>


80
Demo Time – Custom App!

 Inner Ring Bike shop.
     – Using Notes for inventory and sales

     – Wants to add a web interface, and also add some pizzazz with graphs and photos.




81
For more…

 Presentation download
     – http://www.innerringsolutions.com/Connect2013/bp204.pdf


 Demo database download
     – http://www.innerringsolutions.com/Connect2013/bp204_demo.zip




82
Thanks!!

     Craig Schumann
     I nner Ri ng Sol ut i ons, LLC
     http://blog.innerringsolutions.com
          @ZOPEFF
              www. l i nkedi n. com i n/ cr ai gschum
                                   /                 an
              n/




83      © 2013 IBM Corporation
84
Legal disclaimer
     © IBM Corporation 2013. All Rights Reserved.
     The information contained in this publication is provided for informational purposes only. While efforts were made to verify the completeness and accuracy of the information contained in this publication, it is provided
              AS IS without warranty of any kind, express or implied. In addition, this information is based on IBM’s current product plans and strategy, which are subject to change by IBM without notice. IBM shall not be
              responsible for any damages arising out of the use of, or otherwise related to, this publication or any other materials. Nothing contained in this publication is intended to, nor shall have the effect of, creating
              any warranties or representations from IBM or its suppliers or licensors, or altering the terms and conditions of the applicable license agreement governing the use of IBM software.
     References in this presentation to IBM products, programs, or services do not imply that they will be available in all countries in which IBM operates. Product release dates and/or capabilities referenced in this
             presentation may change at any time at IBM’s sole discretion based on market opportunities or other factors, and are not intended to be a commitment to future product or feature availability in any way.
             Nothing contained in these materials is intended to, nor shall have the effect of, stating or implying that any activities undertaken by you will result in any specific sales, revenue growth or other results.
     Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.
     Microsoft and Windows are trademarks of Microsoft Corporation in the United States, other countries, or both.
     Flickr is a trademarks of Yahoo Inc. in the United States, other countries, or both.
     Google is a trademarks of Google Inc. in the United States, other countries, or both.
     All references to Inner Ring Bike Shop refer to a fictitious company and are used for illustration purposes only.




85           © 2013 IBM Corporation

Weitere ähnliche Inhalte

Was ist angesagt?

IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...
IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...
IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...Benedek Menesi
 
how to use fiddler (Ver eng)
how to use fiddler (Ver eng)how to use fiddler (Ver eng)
how to use fiddler (Ver eng)용진 조
 
Massive service basic
Massive service basicMassive service basic
Massive service basicDaeMyung Kang
 
How to build massive service for advance
How to build massive service for advanceHow to build massive service for advance
How to build massive service for advanceDaeMyung Kang
 
Domino Tech School - Upgrading to Notes/Domino V10: Best Practices
Domino Tech School - Upgrading to Notes/Domino V10: Best PracticesDomino Tech School - Upgrading to Notes/Domino V10: Best Practices
Domino Tech School - Upgrading to Notes/Domino V10: Best PracticesChristoph Adler
 
RNUG - HCL Notes V11 Performance Boost
RNUG - HCL Notes V11 Performance BoostRNUG - HCL Notes V11 Performance Boost
RNUG - HCL Notes V11 Performance BoostChristoph Adler
 
IBM Domino / IBM Notes Performance Tuning
IBM Domino / IBM Notes Performance Tuning IBM Domino / IBM Notes Performance Tuning
IBM Domino / IBM Notes Performance Tuning Vladislav Tatarincev
 
Best Practice TLS for IBM Domino
Best Practice TLS for IBM DominoBest Practice TLS for IBM Domino
Best Practice TLS for IBM DominoJared Roberts
 
Binding to multiple datasources on a single xPage
Binding to multiple datasources on a single xPageBinding to multiple datasources on a single xPage
Binding to multiple datasources on a single xPagedominion
 
[Meetup] a successful migration from elastic search to clickhouse
[Meetup] a successful migration from elastic search to clickhouse[Meetup] a successful migration from elastic search to clickhouse
[Meetup] a successful migration from elastic search to clickhouseVianney FOUCAULT
 
Workshop 4: NodeJS. Express Framework & MongoDB.
Workshop 4: NodeJS. Express Framework & MongoDB.Workshop 4: NodeJS. Express Framework & MongoDB.
Workshop 4: NodeJS. Express Framework & MongoDB.Visual Engineering
 
July OpenNTF Webinar - HCL Presents Keep, a new API for Domino
July OpenNTF Webinar - HCL Presents Keep, a new API for DominoJuly OpenNTF Webinar - HCL Presents Keep, a new API for Domino
July OpenNTF Webinar - HCL Presents Keep, a new API for DominoHoward Greenberg
 
IBM Notes Traveler Best Practices
IBM Notes Traveler Best PracticesIBM Notes Traveler Best Practices
IBM Notes Traveler Best Practicesjayeshpar2006
 
IBM Notes Performance Boost - Reloaded (DEV-1185)
IBM Notes Performance Boost - Reloaded (DEV-1185)IBM Notes Performance Boost - Reloaded (DEV-1185)
IBM Notes Performance Boost - Reloaded (DEV-1185)Christoph Adler
 
Domino Server Health - Monitoring and Managing
 Domino Server Health - Monitoring and Managing Domino Server Health - Monitoring and Managing
Domino Server Health - Monitoring and ManagingGabriella Davis
 

Was ist angesagt? (20)

Domino Adminblast
Domino AdminblastDomino Adminblast
Domino Adminblast
 
IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...
IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...
IBM Connect 2014 BP103: Ready, Aim, Fire: Mastering the Latest in the Adminis...
 
how to use fiddler (Ver eng)
how to use fiddler (Ver eng)how to use fiddler (Ver eng)
how to use fiddler (Ver eng)
 
Vue.js
Vue.jsVue.js
Vue.js
 
Massive service basic
Massive service basicMassive service basic
Massive service basic
 
How to build massive service for advance
How to build massive service for advanceHow to build massive service for advance
How to build massive service for advance
 
Domino Tech School - Upgrading to Notes/Domino V10: Best Practices
Domino Tech School - Upgrading to Notes/Domino V10: Best PracticesDomino Tech School - Upgrading to Notes/Domino V10: Best Practices
Domino Tech School - Upgrading to Notes/Domino V10: Best Practices
 
RNUG - HCL Notes V11 Performance Boost
RNUG - HCL Notes V11 Performance BoostRNUG - HCL Notes V11 Performance Boost
RNUG - HCL Notes V11 Performance Boost
 
IBM Domino / IBM Notes Performance Tuning
IBM Domino / IBM Notes Performance Tuning IBM Domino / IBM Notes Performance Tuning
IBM Domino / IBM Notes Performance Tuning
 
60 Admin Tips
60 Admin Tips60 Admin Tips
60 Admin Tips
 
Best Practice TLS for IBM Domino
Best Practice TLS for IBM DominoBest Practice TLS for IBM Domino
Best Practice TLS for IBM Domino
 
Binding to multiple datasources on a single xPage
Binding to multiple datasources on a single xPageBinding to multiple datasources on a single xPage
Binding to multiple datasources on a single xPage
 
[Meetup] a successful migration from elastic search to clickhouse
[Meetup] a successful migration from elastic search to clickhouse[Meetup] a successful migration from elastic search to clickhouse
[Meetup] a successful migration from elastic search to clickhouse
 
Basics of VueJS
Basics of VueJSBasics of VueJS
Basics of VueJS
 
Workshop 4: NodeJS. Express Framework & MongoDB.
Workshop 4: NodeJS. Express Framework & MongoDB.Workshop 4: NodeJS. Express Framework & MongoDB.
Workshop 4: NodeJS. Express Framework & MongoDB.
 
July OpenNTF Webinar - HCL Presents Keep, a new API for Domino
July OpenNTF Webinar - HCL Presents Keep, a new API for DominoJuly OpenNTF Webinar - HCL Presents Keep, a new API for Domino
July OpenNTF Webinar - HCL Presents Keep, a new API for Domino
 
React js
React jsReact js
React js
 
IBM Notes Traveler Best Practices
IBM Notes Traveler Best PracticesIBM Notes Traveler Best Practices
IBM Notes Traveler Best Practices
 
IBM Notes Performance Boost - Reloaded (DEV-1185)
IBM Notes Performance Boost - Reloaded (DEV-1185)IBM Notes Performance Boost - Reloaded (DEV-1185)
IBM Notes Performance Boost - Reloaded (DEV-1185)
 
Domino Server Health - Monitoring and Managing
 Domino Server Health - Monitoring and Managing Domino Server Health - Monitoring and Managing
Domino Server Health - Monitoring and Managing
 

Andere mochten auch

REST services and IBM Domino/XWork - DanNotes 19-20. november 2014
REST services and IBM Domino/XWork - DanNotes 19-20. november 2014REST services and IBM Domino/XWork - DanNotes 19-20. november 2014
REST services and IBM Domino/XWork - DanNotes 19-20. november 2014John Dalsgaard
 
Domino OSGi Development
Domino OSGi DevelopmentDomino OSGi Development
Domino OSGi DevelopmentPaul Fiore
 
Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...
Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...
Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...Mark Roden
 
MWLUG 2015 - AD114 Take Your XPages Development to the Next Level
MWLUG 2015 - AD114 Take Your XPages Development to the Next LevelMWLUG 2015 - AD114 Take Your XPages Development to the Next Level
MWLUG 2015 - AD114 Take Your XPages Development to the Next Levelbalassaitis
 
ConnectED2015: IBM Domino Applications in Bluemix
ConnectED2015: 	IBM Domino Applications in BluemixConnectED2015: 	IBM Domino Applications in Bluemix
ConnectED2015: IBM Domino Applications in BluemixMartin Donnelly
 
Building mobile applications with Vaadin TouchKit
Building mobile applications with Vaadin TouchKitBuilding mobile applications with Vaadin TouchKit
Building mobile applications with Vaadin TouchKitSami Ekblad
 
Fun With SHA2 Certificates
Fun With SHA2 CertificatesFun With SHA2 Certificates
Fun With SHA2 CertificatesGabriella Davis
 
IBM Presents the IBM Notes and Domino Roadmap
IBM Presents the IBM Notes and Domino RoadmapIBM Presents the IBM Notes and Domino Roadmap
IBM Presents the IBM Notes and Domino RoadmapTeamstudio
 
Jak zlepšit zabezpečení čtvrtiny celého webu
Jak zlepšit zabezpečení čtvrtiny celého webuJak zlepšit zabezpečení čtvrtiny celého webu
Jak zlepšit zabezpečení čtvrtiny celého webuMichal Špaček
 
Types and components of computer system
Types and components of computer systemTypes and components of computer system
Types and components of computer systemmkhisalg
 
Introduction to Basic Computer Concepts Presentation
Introduction to Basic Computer Concepts PresentationIntroduction to Basic Computer Concepts Presentation
Introduction to Basic Computer Concepts PresentationAna Tan
 
Computer Basics 101 Slide Show Presentation
Computer Basics 101 Slide Show PresentationComputer Basics 101 Slide Show Presentation
Computer Basics 101 Slide Show Presentationsluget
 
Components of a computer system
Components of a computer systemComponents of a computer system
Components of a computer systemlistergc
 

Andere mochten auch (14)

REST services and IBM Domino/XWork - DanNotes 19-20. november 2014
REST services and IBM Domino/XWork - DanNotes 19-20. november 2014REST services and IBM Domino/XWork - DanNotes 19-20. november 2014
REST services and IBM Domino/XWork - DanNotes 19-20. november 2014
 
Domino OSGi Development
Domino OSGi DevelopmentDomino OSGi Development
Domino OSGi Development
 
Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...
Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...
Connect 2014 - EXTJS in XPages: Modernizing IBM Notes Views Without Sacrifici...
 
MWLUG 2015 - AD114 Take Your XPages Development to the Next Level
MWLUG 2015 - AD114 Take Your XPages Development to the Next LevelMWLUG 2015 - AD114 Take Your XPages Development to the Next Level
MWLUG 2015 - AD114 Take Your XPages Development to the Next Level
 
ConnectED2015: IBM Domino Applications in Bluemix
ConnectED2015: 	IBM Domino Applications in BluemixConnectED2015: 	IBM Domino Applications in Bluemix
ConnectED2015: IBM Domino Applications in Bluemix
 
Building mobile applications with Vaadin TouchKit
Building mobile applications with Vaadin TouchKitBuilding mobile applications with Vaadin TouchKit
Building mobile applications with Vaadin TouchKit
 
Fun With SHA2 Certificates
Fun With SHA2 CertificatesFun With SHA2 Certificates
Fun With SHA2 Certificates
 
Basic Computer Skills Seminar
Basic Computer Skills Seminar Basic Computer Skills Seminar
Basic Computer Skills Seminar
 
IBM Presents the IBM Notes and Domino Roadmap
IBM Presents the IBM Notes and Domino RoadmapIBM Presents the IBM Notes and Domino Roadmap
IBM Presents the IBM Notes and Domino Roadmap
 
Jak zlepšit zabezpečení čtvrtiny celého webu
Jak zlepšit zabezpečení čtvrtiny celého webuJak zlepšit zabezpečení čtvrtiny celého webu
Jak zlepšit zabezpečení čtvrtiny celého webu
 
Types and components of computer system
Types and components of computer systemTypes and components of computer system
Types and components of computer system
 
Introduction to Basic Computer Concepts Presentation
Introduction to Basic Computer Concepts PresentationIntroduction to Basic Computer Concepts Presentation
Introduction to Basic Computer Concepts Presentation
 
Computer Basics 101 Slide Show Presentation
Computer Basics 101 Slide Show PresentationComputer Basics 101 Slide Show Presentation
Computer Basics 101 Slide Show Presentation
 
Components of a computer system
Components of a computer systemComponents of a computer system
Components of a computer system
 

Ähnlich wie BP204 - Take a REST and put your data to work with APIs!

Advanced Web Development
Advanced Web DevelopmentAdvanced Web Development
Advanced Web DevelopmentRobert J. Stein
 
WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...Fabio Franzini
 
Google Cloud lightning talk @MHacks
Google Cloud lightning talk @MHacksGoogle Cloud lightning talk @MHacks
Google Cloud lightning talk @MHackswesley chun
 
Serverless ML Workshop with Hopsworks at PyData Seattle
Serverless ML Workshop with Hopsworks at PyData SeattleServerless ML Workshop with Hopsworks at PyData Seattle
Serverless ML Workshop with Hopsworks at PyData SeattleJim Dowling
 
Ajaxworld Opensocial Presentation
Ajaxworld Opensocial PresentationAjaxworld Opensocial Presentation
Ajaxworld Opensocial PresentationChris Schalk
 
Getting Started with DrupalGap
Getting Started with DrupalGapGetting Started with DrupalGap
Getting Started with DrupalGapAlex S
 
Having Fun Building Web Applications (Day 1 Slides)
Having Fun Building Web Applications (Day 1 Slides)Having Fun Building Web Applications (Day 1 Slides)
Having Fun Building Web Applications (Day 1 Slides)Clarence Ngoh
 
Semantic technologies in practice - KULeuven 2016
Semantic technologies in practice - KULeuven 2016Semantic technologies in practice - KULeuven 2016
Semantic technologies in practice - KULeuven 2016Aad Versteden
 
Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08Ari Leichtberg
 
From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...
From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...
From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...Connected Data World
 
Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)
Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)
Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)Ido Green
 
Rits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce LightningRits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce LightningRight IT Services
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Tech Community
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Tech Community
 
Serverless GraphQL for Product Developers
Serverless GraphQL for Product DevelopersServerless GraphQL for Product Developers
Serverless GraphQL for Product DevelopersSashko Stubailo
 
Intro to jQuery @ Startup Institute
Intro to jQuery @ Startup InstituteIntro to jQuery @ Startup Institute
Intro to jQuery @ Startup InstituteRafael Gonzaque
 
Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...
Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...
Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...Carlos Tomas
 

Ähnlich wie BP204 - Take a REST and put your data to work with APIs! (20)

Advanced Web Development
Advanced Web DevelopmentAdvanced Web Development
Advanced Web Development
 
WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...WebNet Conference 2012 - Designing complex applications using html5 and knock...
WebNet Conference 2012 - Designing complex applications using html5 and knock...
 
Google Cloud lightning talk @MHacks
Google Cloud lightning talk @MHacksGoogle Cloud lightning talk @MHacks
Google Cloud lightning talk @MHacks
 
Uma SunilKumar Resume
Uma SunilKumar ResumeUma SunilKumar Resume
Uma SunilKumar Resume
 
Serverless ML Workshop with Hopsworks at PyData Seattle
Serverless ML Workshop with Hopsworks at PyData SeattleServerless ML Workshop with Hopsworks at PyData Seattle
Serverless ML Workshop with Hopsworks at PyData Seattle
 
Ajaxworld Opensocial Presentation
Ajaxworld Opensocial PresentationAjaxworld Opensocial Presentation
Ajaxworld Opensocial Presentation
 
Xamarin microsoft graph
Xamarin microsoft graphXamarin microsoft graph
Xamarin microsoft graph
 
Mobile optimization
Mobile optimizationMobile optimization
Mobile optimization
 
Getting Started with DrupalGap
Getting Started with DrupalGapGetting Started with DrupalGap
Getting Started with DrupalGap
 
Having Fun Building Web Applications (Day 1 Slides)
Having Fun Building Web Applications (Day 1 Slides)Having Fun Building Web Applications (Day 1 Slides)
Having Fun Building Web Applications (Day 1 Slides)
 
Semantic technologies in practice - KULeuven 2016
Semantic technologies in practice - KULeuven 2016Semantic technologies in practice - KULeuven 2016
Semantic technologies in practice - KULeuven 2016
 
Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08Opensocial Haifa Seminar - 2008.04.08
Opensocial Haifa Seminar - 2008.04.08
 
From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...
From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...
From Knowledge Graphs to AI-powered SEO: Using taxonomies, schemas and knowle...
 
Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)
Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)
Entrepreneurship Tips With HTML5 & App Engine Startup Weekend (June 2012)
 
Rits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce LightningRits Brown Bag - Salesforce Lightning
Rits Brown Bag - Salesforce Lightning
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needs
 
Microsoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needsMicrosoft Graph: Connect to essential data every app needs
Microsoft Graph: Connect to essential data every app needs
 
Serverless GraphQL for Product Developers
Serverless GraphQL for Product DevelopersServerless GraphQL for Product Developers
Serverless GraphQL for Product Developers
 
Intro to jQuery @ Startup Institute
Intro to jQuery @ Startup InstituteIntro to jQuery @ Startup Institute
Intro to jQuery @ Startup Institute
 
Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...
Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...
Build a notepad application with PHP, MongoDB, and IBM Bluemix - by Vikram Va...
 

Kürzlich hochgeladen

DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbuapidays
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 

Kürzlich hochgeladen (20)

DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 

BP204 - Take a REST and put your data to work with APIs!

  • 1. BP204 Take a REST and put your data to work with APIs Craig Schumann | Inner Ring Solutions © 2013 IBM Corporation
  • 2. Agenda  Background  Practical Examples from real life  Designing guidelines for creating your own APIs  How to create your own APIs and free your data 2 © 2013 IBM Corporation
  • 3. House keeping  IBM Lotus Domino®  IBM Domino®  IBM Lotus Notes®  IBM Notes®  IBM Lotus Designer®  IBM Designer® 3
  • 4. 4
  • 5. So much data….  What this talk is about is freeing your data 5
  • 6. Public data….  What this talk is about is freeing your data 6
  • 7. Enterprise data….  What this talk is about is freeing your data 7
  • 8. Bring it together…  What this talk is about is freeing your data 8
  • 9. All in one app  What this talk is about is freeing your data 9
  • 10. How about sharing?  What this talk is about is freeing your data 10
  • 11. What are APIs  APIs are a way to get access to data and functionality of your application without providing UI.  They can be implemented in almost every way imaginable ─ Android apps use public java packages, etc. ─ Developing an iOS application, you use the iOS API via C header files. ─ Web applications also have APIs in the form of Web services, or even just URLS. A permalink is a form of web API. Bottom line - An API makes it easier for other people or applications to access your data or features. 11 © 2013 IBM Corporation
  • 12. What are APIs  APIs have been around a long time, and it gives others access to your system via a public, documented interface.  Provides public paths to into more proprietary systems. - WIN32 - Notes BE Objects - NotesCAPI - iOS, Android  They give you the ability to create new applications on top of existing data / platforms. This is not to hide all your secret sauce (though it could be)! It is more to keep things simple for your users. To give people access to the good stuff without burdening them with the details of how the back end works. 12 © 2013 IBM Corporation
  • 13. What is a WEB API? A web API is nothing more that an API (access to your stuff) that people use over HTTP - AKA web services Yesterday when you talked about web services, you were talking about SOAP Simple Object access protocol. Today the trend these days is to build web services around REST (REpresentational State Transfer). REST is literally what the wide web is based on. 13
  • 14. Web Applications with public APIs  Tell people what you had for lunch or the product you are about to launch: – Connections / Facebook / Twitter (https://dev.twitter.com/docs/api)  Show your sales for the month: – Google Charts (https://developers.google.com/chart/)  Send a text message from your web app – Twillio (http://www.twilio.com/docs/api/rest)  Find pictures for your presentation? – Flickr (http://www.flickr.com/services/api/)  Blog about your new product – WordPress.com REST API (http://developer.wordpress.com/docs/api/)  Netflix – Pick a movie to watch now your app is launched! (http://developer.netflix.com/docs) 14 © 2013 IBM Corporation
  • 15. Why create an API?  Break apart your application and the data. By providing an API: – You don't have to expose the nitty-gritty of how your app stores data. – You create a common way to access your data. – APIs force you to separate your client related code from your data related code. Then by doing this, anyone can create a client. And the client can be anything - mobile, desktop, web, native, anything. – If you are thinking about creating mobile versions of your applications, having an API to access the data will be huge. 15
  • 16. Why create an API?  Don't get caught in the idea that XPages are the only way to access Domino data. API access to your data can free you from a lot of constraints.  A simple document focused API for example will make it easy to create any sort of mobile app you want. Want to create native iOS app? Great! Want to create a mobile web app? Fantastic! Do you need a desktop application? Right on! In all these cases, the server side has not changed at all. Your client app is merely a wrapper around your API! 16
  • 17. 17
  • 18. Example - Performance So lets say I have a web page with this
  • 21. Working with data How about this?
  • 22. 22
  • 23. Working with data  Start with a basic Notes view in XPages  Add an onclick event that ties into a client side JavaScript event 23
  • 24. Working with data  Start with a basic Notes view in XPages  Add an onclick event that ties into a client side JavaScript event <xp:viewPanel var="rowData" rows="10" id="viewPanel1" viewStyleClass="viewPanel" rowClasses="viewPanelRow"> <xp:this.facets> <xp:pager partialRefresh="true" layout="Previous Group Next" xp:key="headerPager" id="pager1" for="viewPanel1"> </xp:pager> </xp:this.facets> <xp:this.data> <xp:dominoView var="view1" databaseName="ls13irsbikes_inventory.nsf" viewName="demoView"> </xp:dominoView> </xp:this.data> <xp:this.rowAttrs> <xp:attr value="javascript:loadDocument('#{javascript:rowData.getUniversalID()}')" name="onclick"> </xp:attr> </xp:this.rowAttrs> [……] </xp:viewPanel> 24
  • 25. Working with data  The onclick event then triggers 3 things to happen – The full document is fetched in JSON format – One of the Google charts is updated with the sales for that brand of bike – Flickr is searched for images tagged with the brand and model of bike selected function loadDocument(unid){ // get the document we have selected getNotesDocument( unid, "ls13/irsbikes_inventory.nsf", function(doc){ // get related flickr images flickerAPIImages(doc.getItem("brand")+","+doc.getItem("model")); // update sales data googleChartsAPI(doc.getItem("brand")); }) } 25
  • 26. Working with data  Step one is to get the document…  Domino can do this for you, but it’s better to have a little more control over what you get. function getNotesDocument( docid, db, callback ){ var url = './apiv1.xsp?f=document'; url += "&db=" + db; url += "&documentId=" + docid; $.getJSON(url,function(data){ var doc = new NotesDocument(data); callback(doc); }); } 26
  • 27. Working with data  When you control the API, you control the data and how it is represented. function getDocument(){ var db:NotesDatabase = session.getDatabase("", param['db']); var doc:NotesDocument = db.getDocumentByUNID(param['documentId']); try{ var docXML = doc.generateXML(); var writer = facesContext.getResponseWriter(); var excon = facesContext.getExternalContext(); excon.getResponse().setContentType("application/json"); writer.write( org.json.XML.toJSONObject(docXML).toString()); } catch(e){ print(e.toString()) } } 27
  • 28. Working with data  The chart is updated with an API call to get the data needed  The chart is drawn with the Google charts engine using the data that is returned function googleChartsAPI(brand){ var url = "./apiv1.xsp?f=sales&k=months"; if( null != brand && "" != brand ){ url += "&brand=" + brand; } $.getJSON(url, function(d) { [Google charts code] }) } 28
  • 29. Working with data  The flicker search is done the same way. 29
  • 30. Working with data  The flicker search is done the same way… function flickerAPIImages(search){ /* * Flickr Photo API * http://www.flickr.com/services/api/flickr.photos.search.html */ search = search.replace(/,/g,"+"); // var URL = "http://api.flickr.com/services/rest/?method=flickr.photos.search"; url += "&api_key=<your api key goes here>"; url += "&tags=cycling%2C+mountain&text="+search+"+%20bikes"; url += "&per_page=5&format=json&nojsoncallback=1"; $.getJSON( URL, function(d) { var source = $("#entry-template").html(); var template = Handlebars.compile(source); var context = d.photos; var html = template(context); $('#imageInner').html(html); }) } 30
  • 31. Working with data  XPages - server side is not the place to do it – Rendering a page should not wait for a response from some other site. – Things get messy quick with a mix of server side and client side code updating the page  In general don't fill your page with tons of data – Valuable data is trapped and mixed in with the rest of the UI – There is a lot of different kinds of data here, from multiple sources.  Partial refresh is not always the answer either. – Hard to chain things together so one value affects many others – could render the whole page
  • 32. Data trapped in the UI???  What happens when the client isn’t always a browser?  Other clients might not want HTML  Example - XSnippets 32
  • 33. Example - XSnippets  XSnippets – OpenNTF.org project – http://openntf.org/XSnippets.nsf/home.xsp – Template can be downloaded and customized at http://xsnippets.openntf.org/  Currently there is only a web interface 33
  • 34. XSnippets – browser client That is enough Right? 34
  • 37. 37
  • 38. Options  SOAP ─ ‘Classic’ Web services, Strong "object model" ─ Message based / transactional ─ Hard to do simple things like getting a list of things ─ been there done that....  REST ─ resources / Object model based ─ resources can be anything you can create a URI for. ─ path oriented ─ database/collection (like a view) ─ database/collection/entity (like a document) 38 © 2013 IBM Corporation
  • 39. REST REST is not a standard. REST is a style, a way to build a web application. That being said, REST does make use of standards. HTTP, XML, URLs REST works with resources as collections and objects. A resource can be anything you are interested in. For example: www.example.com/customers/IBM Would be a request for the IBM customer resource. A web server can respond with a representation of the resource IBM.html for example, an XPage customer.xsp, or just an XML or JSON document with the IBM specific data. Notice there is no “VERB” in the resource URI…. 39 © 2013 IBM Corporation
  • 40. REST and URLs The key difference with a RESTfull service and a SOAP service is the way you use the HTTP verbs. SOAP encourages the method to define the verb - getCustomers. REST uses the HTTP methods* to define the operation GET /customers * http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html 40 © 2013 IBM Corporation
  • 41. REST - GET You have probably head about HTTP GET. GET is the most basic action a client can do. With GET the client is requesting a read only copy of a resource. 41 © 2013 IBM Corporation
  • 42. REST - POST  You are also probably familiar with POST. This the most common thing to do when sending data back to the server - submitting a form for example.  POST is should be used when creating or updating resources when the resulting URI is not known.  RESTfull services will also make use of PUT and DELETE, and this is where a true RESTfull service will diverge a bit from the common use of POST. 42 © 2013 IBM Corporation
  • 43. REST - PUT  PUT is used when you are updating an existing resource. – PUT is used when you know the path to the resource. – PUT can create resources if one does not already exist  POST vs PUT – POST in form submission because you don’t know what the URL to the new resource is going to be. – PUT requires the URL to resource to be known – HTML FORMs only support GET and POST 43 © 2013 IBM Corporation
  • 44. REST - DELETE DELETE does what it says on the tin - deletes a resource. 44 © 2013 IBM Corporation
  • 45. REST verbs  Client side JavaScript with Dojo dojo.xhrPut ({ url: '/api_v1.xsp', putData: ‘data to send to server', handleAs: ‘text’, error: function(result) { // Whoops } });  Java URL url; try { url = new URL(uri); HttpsURLConnection conn = (HttpsURLConnection)url.openConnection(); conn.setDoInput(true); conn.setDoOutput(true); conn.setRequestMethod(“PUT"); } 45
  • 46. REST verbs – XPages example <?xml version="1.0" encoding="UTF-8"?> <xp:view xmlns:xp="http://www.ibm.com/xsp/core" rendered='false'> <xp:this.afterRenderResponse><![CDATA[#{javascript: var request = facesContext.getExternalContext().getRequest(); var writer = facesContext.getResponseWriter(); var method = request.getMethod(); if( method === "GET" ){ writer.write("You did a "GET""); } else if( method === "POST" ){ writer.write("You did a "POST""); } else if( method === "PUT" ){ writer.write("You did a "PUT""); } else if( method === "DELETE" ){ writer.write("You did a "DELETE""); } }]]></xp:this.afterRenderResponse> </xp:view> 46
  • 47. REST verbs – XPages example 47
  • 48. REST verbs – XPages example DEV-HTTP-CLIENT (Chrome App) http://bit.ly/Wj8U67 48
  • 49. REST - resources  REST uses HTTP to provide the VERB to the resource  Since the verb (get,post,etc) is part of the request, you shouldn't use verbs in the URL to the resource, only nouns.  If your data has Objects like customers, projects, meetings, etc. the REST API should use the same object names www.example.com/customers?id=IBM vs www.example.com/getCustomer?customer=IBM 49 © 2013 IBM Corporation
  • 50. REST URLs should point to logical resources, not physical. www.example.com/customers/IBM vs www.example.com/customers/IBM.html These kinds of URLs are not easy in Domino. Luckily REST is a design principle, and not a standard! You can still design a RESTfull api with Domino. 50 © 2013 IBM Corporation
  • 51. RESTful data RESTful APIs typically don't deal in HTML. HTML is UI, Your REST API shouldn't be worrying about or injecting UI  Don’t include HTML in your RESTful data  Strictly speaking, the format for data can be anything, but it’s usually:  XML  JSON/JSONP (AKA XML with curly braces). 51 © 2013 IBM Corporation
  • 52. REST and errors Use error codes in the response ─ 2xx == all good ─ 4xx == client messed something up ─ 5xx == server messed something up 52 © 2013 IBM Corporation
  • 53. RESTful errors 53 © 2013 IBM Corporation
  • 54. API Versioning You must version your API! Versioning your API means that you don't need to update all your clients immediately, if at all, when you add or change your API**. Make the version part of the resource, not a parameter. Make it explicit. www.example.com/v1/customers/IBM vs www.example.com/customers/IBM?v=1 **You will change it, so just get it out of the way and design it into V1 54 © 2013 IBM Corporation
  • 55. API Versioning 55 © 2013 IBM Corporation
  • 56. API Authentication A RESTfull application should also be stateless. So this means that you should not be storing session information server side. This is Domino so you don't have much control over this, but in general you shouldn't be using appScope or sessionScope variables to store anything.  Public / No authorization needed  HTTP Authentication ─ Server handles the login ─ All HTTP requests must contain the login info via Authorization header ─ Database ACL is set to require authentication (Anonymous=No Access)  Token Authentication ─ You handle the login ─ an API key is generated for client access. That key is used as the login credentials. Not really security, but limits access to the data to a known set of users and gives application control over who has access without having to manage the ACL ─ Database ACL is more open 56 © 2013 IBM Corporation
  • 57. 57
  • 58. Old school  &ReadViewEntries  Supported since R6  Gives you a dump of a view in XML or JSON format  Pros  Cons – Built in so performance is good – No control over the output – No coding needed – Does not support JSONP – XML is a little more useful than the – There are a few bugs that can cause JSON version the JSON output to be invalid – There is no equiv for docs so everything you need must be in the view – Not really an API.. 58
  • 61. POA (Plain old Agents)  These don’t require anything special and can do all the same things we talked about previously.  Can use Java or LotusScript. 61
  • 62. POA (Plain old Agents) Sub Initialize Dim s As New NotesSession Dim db As New NotesDatabase("", "ls13/irsbikes_inventory.nsf") Dim docs As NotesDocumentCollection Set docs = db.AllDocuments Dim d As NotesDocument Set d = docs.getfirstdocument Print "Content-Type:application/xml" Print |<?xml version="1.0" encoding="UTF-8"?>| Print |<bikes>| while Not d Is Nothing Print "<bike>" Print "<brand>" + d.brand(0) + "</brand>" Print "<model>" + d.model(0) + "</model>" Print "</bike>" Set d = docs.Getnextdocument(d) Wend Print |</bikes>| End Sub 62
  • 63. POA (Plain old Agents) 63
  • 64. POA (Plain old Agents) public class JavaAgent extends AgentBase { public void NotesMain() { try { Session session = getSession(); AgentContext agentContext = session.getAgentContext(); Database db = session.getDatabase("", "ls13/irsbikes_inventory.nsf"); DocumentCollection docs = db.getAllDocuments(); Document doc = docs.getFirstDocument(); java.io.Writer sw = new java.io.StringWriter(); PrintWriter ao = getAgentOutput(); ao.println("Content-type: text/xml"); ao.println("<bikes>"); while(null!=doc){ // write the document out doc.generateXML(sw); doc = docs.getNextDocument(doc); } sw.flush(); ao.print(sw.toString()); ao.println("</bikes>"); } catch(Exception e) { e.printStackTrace(); } } } 64
  • 65. Domino and REST  Introduced in 8.5.3  4 built in options – Domino Data Service – XPages REST Services Control – Custom Database Servlet – Custom Wink Servlet 65
  • 66. Domino and REST  Pros  Cons – Built in so support and performance is – DDS Needs to be enabled on the good server (admins need to be involved) – No coding needed – Very granular – database, view – Very granular properties – URLs are not app specific. This is Domino’s API = views and documents – No coding – can’t really expose logical application objects – Not documented very well (yet) 66
  • 67. Domino and REST – Domino Data Services 67
  • 69. Domino and REST – Domino Data Services 69
  • 70. Domino and REST – Domino Data Services  http://{host}/api/data [ { "@title":"Activity Trends (MADER)", "@filepath":"activity.nsf", "@replicaid":"852578220B751506", "@template":"StdActivityTrendsDatabase", "@href":"http://localhost:80/activity.nsf/API/data/collections" }, { "@title":"Administration Requests", "@filepath":"admin4.nsf", "@replicaid":"8525782203751506", "@template":"StdR4AdminRequests", "@href":"http://localhost:80/admin4.nsf/API/data/collections" }, …… ] 70
  • 71. Domino and REST – Domino Data Services  http://{host}/{path}/api/data/collections [ { "@title":"By Type", "@folder":false, "@private":false, "@modified":"2012-12-19T20:27:13Z", "@unid":"0AC52D85954AB7E785257AD9005D6E35", "@href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/collections/unid/0AC52D85954AB7E785257AD9005D6E35" }, { "@title":"By Size", "@folder":false, "@private":false, "@modified":"2012-12-19T20:27:13Z", "@unid":"66ED263FEEC2CF7485257AD9005D3342", "@href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/collections/unid/66ED263FEEC2CF7485257AD9005D3342" }, …… ] 71
  • 72. Domino and REST – Domino Data Services  http://{host}/{path}/api/data/collections/name/{view name}  http://{host}/{path}/api/data/collections/unid/{view unid} [ { "@href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/collections/name/demoView/unid/6783AB7D38FACE2A85257AD9005BDC35", "@link": { "rel":"document", "href":"http://localhost:80/ls13/irsbikes_inventory.nsf/API/data/documents/unid/6783AB7D38FACE2A85257AD9005BDC35" }, "@entryid":"1-6783AB7D38FACE2A85257AD9005BDC35", "@unid":"6783AB7D38FACE2A85257AD9005BDC35", "@noteid":"906", "@position":"1", "@siblings":22, "@form":"inventory", …. }, ….. ] 72
  • 73. Domino and REST – REST Services Control  The REST Services Custom Control comes with the Extension Library.  No Coding!  Add to an XPage and set the ‘pathInfo’ paramter.  Different types of resources can be retrieved – databaseCollectionJsonService - Read the list of databases on the server. – viewCollectionJsonService - Read the list of views and folders in a database. – viewJsonService - Read the entries in a view or folder. – documentJsonService - Create, read, update and delete documents.  Adds to the path for the XPage for specific resources 73
  • 74. Domino and REST – REST Services Control 74
  • 75. Domino and REST – REST Services Control 75
  • 76. Domino and REST – REST Services Control http://localhost/ls13/irsbikes_web.nsf/restControl.xsp/bikes 76
  • 77. Domino and REST – Domino Data Services  More on OpenNTF – Niklas Heidloff - http://www.openntf.org/blogs/openntf.nsf/d6plinks/NHEF-8JGGPE • Documentation • Examples • Video 77
  • 78. “XAgents”  XPages with rendered=‘false’  Can write your API in Java or Server Side JavaScript  Keeps you in the same frame of mind as the rest of your XPages development. 78
  • 79. “XAgents” <?xml version="1.0" encoding="UTF-8"?> <xp:view xmlns:xp="http://www.ibm.com/xsp/core" rendered='false'> <xp:this.afterRenderResponse><![CDATA[#{javascript: var externalContext = facesContext.getExternalContext(); var response = externalContext.getResponse(); var request = externalContext.getRequest(); if( !param.containsKey("p") ){ response.setStatus(400); response.setContentType("application/json"); var writer = facesContext.getResponseWriter(); writer.write("{ "code":400, "text":"Bad Parameter", "message":"Missing method call parameter 'p'" }"); return; } var s = new org.openntf.api.snippet(); s.service( request, response); }]]> </xp:this.afterRenderResponse> </xp:view> 79
  • 80. “Xagents” + JAVA = Happy <?xml version="1.0" encoding="UTF-8"?> <xp:view xmlns:xp="http://www.ibm.com/xsp/core" rendered='false'> <xp:this.afterRenderResponse><![CDATA[#{javascript: var externalContext = facesContext.getExternalContext(); var response = externalContext.getResponse(); var request = externalContext.getRequest(); if( !param.containsKey("p") ){ response.setStatus(400); response.setContentType("application/json"); var writer = facesContext.getResponseWriter(); writer.write("{ "code":400, "text":"Bad Parameter", "message":"Missing method call parameter 'p'" }"); return; } var s = new org.openntf.api.snippet(); s.service( request, response); }]]> </xp:this.afterRenderResponse> </xp:view> 80
  • 81. Demo Time – Custom App!  Inner Ring Bike shop. – Using Notes for inventory and sales – Wants to add a web interface, and also add some pizzazz with graphs and photos. 81
  • 82. For more…  Presentation download – http://www.innerringsolutions.com/Connect2013/bp204.pdf  Demo database download – http://www.innerringsolutions.com/Connect2013/bp204_demo.zip 82
  • 83. Thanks!! Craig Schumann I nner Ri ng Sol ut i ons, LLC http://blog.innerringsolutions.com @ZOPEFF www. l i nkedi n. com i n/ cr ai gschum / an n/ 83 © 2013 IBM Corporation
  • 84. 84
  • 85. Legal disclaimer © IBM Corporation 2013. All Rights Reserved. The information contained in this publication is provided for informational purposes only. While efforts were made to verify the completeness and accuracy of the information contained in this publication, it is provided AS IS without warranty of any kind, express or implied. In addition, this information is based on IBM’s current product plans and strategy, which are subject to change by IBM without notice. IBM shall not be responsible for any damages arising out of the use of, or otherwise related to, this publication or any other materials. Nothing contained in this publication is intended to, nor shall have the effect of, creating any warranties or representations from IBM or its suppliers or licensors, or altering the terms and conditions of the applicable license agreement governing the use of IBM software. References in this presentation to IBM products, programs, or services do not imply that they will be available in all countries in which IBM operates. Product release dates and/or capabilities referenced in this presentation may change at any time at IBM’s sole discretion based on market opportunities or other factors, and are not intended to be a commitment to future product or feature availability in any way. Nothing contained in these materials is intended to, nor shall have the effect of, stating or implying that any activities undertaken by you will result in any specific sales, revenue growth or other results. Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both. Microsoft and Windows are trademarks of Microsoft Corporation in the United States, other countries, or both. Flickr is a trademarks of Yahoo Inc. in the United States, other countries, or both. Google is a trademarks of Google Inc. in the United States, other countries, or both. All references to Inner Ring Bike Shop refer to a fictitious company and are used for illustration purposes only. 85 © 2013 IBM Corporation