Interface MarketoClient
public interface MarketoClient
A client for interacting with Marketo's API.
-
Method Summary
Modifier and TypeMethodDescription@NotNull StringgetApiToken(@NotNull MarketoClientConfiguration config) Retrieve an API token used for interacting with the Marketo API.@NotNull List<MarketoField>getFields(@NotNull MarketoClientConfiguration config) Retrieve all of the available forms from the current organization in Marketo.@NotNull List<MarketoForm>getForms(@NotNull MarketoClientConfiguration config) Retrieve all of the available forms from the current organization in Marketo.@NotNull org.apache.http.impl.client.CloseableHttpClientRetrieve a HttpClient for interacting with the Marketo API
-
Method Details
-
getApiToken
@NotNull @NotNull String getApiToken(@NotNull @NotNull MarketoClientConfiguration config) throws MarketoApiException Retrieve an API token used for interacting with the Marketo API.- Parameters:
config- the configuration to use to retrieve the token- Returns:
- a valid Marketo API Token
- Throws:
IOException- an error occurs retrieving the tokenMarketoApiException
-
getHttpClient
@NotNull @NotNull org.apache.http.impl.client.CloseableHttpClient getHttpClient()Retrieve a HttpClient for interacting with the Marketo API- Returns:
- the httpclient
-
getForms
@NotNull @NotNull List<MarketoForm> getForms(@NotNull @NotNull MarketoClientConfiguration config) throws MarketoApiException Retrieve all of the available forms from the current organization in Marketo.- Parameters:
config- the configuration for this request- Returns:
- the full list of available forms
- Throws:
IOException- an exception occurs interacting with the APIMarketoApiException
-
getFields
@NotNull @NotNull List<MarketoField> getFields(@NotNull @NotNull MarketoClientConfiguration config) throws MarketoApiException Retrieve all of the available forms from the current organization in Marketo.- Parameters:
config- the configuration for this request- Returns:
- the full list of available forms
- Throws:
IOException- an exception occurs interacting with the APIMarketoApiException
-