// This module is included in the following assemblies:
// as_connecting-to-odata.adoc

[id='creating-odata-connections_{context}']
= Creating a connection to an OData service

In an integration, to obtain, update, create, or delete
entities that are managed by an OData service, you must first create a connection to 
that OData service. You can create a connection for version 2 or a version 4 OData.

.Prerequisites

* You must know the base URL for the OData service that you want
to connect to. 
* If that service uses authentication then you must have the 
required credentials, and, if required, an SSL certificate. 
However, most OData services are public and do not require 
authentication. 

.Procedure

. In {prodname}, in the left panel, click *Connections* to
display any available connections.
. Click *Create Connection* to display
connectors.  
. Click the *OData v2* or the *OData v4* connector.
. To configure the connection:
.. In the *Service Root URL* field, enter the base URL for the 
OData service that you want to access. 
.. In the *User Name* field, if the service uses basic authentication, 
then enter your user name.
.. In the *Password* field, if the service uses basic authentication, 
then enter your password. 
.. In the *Server Certificate* field, if the service requires it, paste the content of an SSL 
certificate. 
+
Typically, a public OData service does not require a certificate in addition to the 
certificates provided by the browser. However, for an internal OData service, 
you might have created your own SSL certificate and self-signed it. Since this 
certificate is not trusted by a certificate authority, connections to your OData 
service would fail. To enable connections, paste the self-signed certificate here. 
+
One way to get the certificate is to load the service in a browser. 
The steps after that depend on which browser you are using, but it will be 
something like the following: click the *Not secure* padlock symbol next to the 
address bar, then click *View Certificate*, export the displayed certificate to 
a file, copy the certificate, and paste it into this field. 

. Click *Validate*. {prodname} immediately tries to validate the 
connection and displays a message that indicates whether 
validation is successful. If validation fails, revise the input 
parameter(s) and try again.
. When validation is successful, click *Next*.
. In the *Name* field, enter your choice of a name that
helps you distinguish this connection from any other connections.
For example, you might enter `OData North`.
. In the *Description* field, optionally enter any information that
is helpful to know about this connection. 
. Click *Save* to see that the connection you 
created is now available. If you entered the example name, you would 
see that *OData North* appears as a connection that you can 
choose to add to an integration. 

.Next step
Add your OData connection to an integration. 
