RESTful API

 

/api/v2/settings

Request Type
GET
 
Returns the application's settings as defined on the Stitchz Login Settings page. No user identity string required.
 
Example URL
https://example.stitchz.net/api/v2/settings
 
Request
Required Parameter Type Description
yes Bearer string The application's unique Oauth2 bearer token (access token) in the request header
  Format string The format of the authenticated Stitchz response, XML, JSON, JSONP. A query string parameter can be included in the request (e.g. ?format=json) or a header variable of "Accept" with the proper value, e.g. 'application/json', 'application/xml', etc. The default response is in "JSON" format.
Example Request
$ curl -H "Authorization: Bearer e72e16c7e42f292c6912e7710c838347ae178b4a"
-H "Accept: application/json"
-A "example client"
https://example.stitchz.net/api/v2/settings

GET /api/v2/settings HTTP/1.1
User-Agent: example client
Host: example.stitchz.net
Accept: application/json
Authorization: Bearer e72e16c7e42f292c6912e7710c838347ae178b4a
Response
Field Type Description
Name string The name of the application and will be used in the unique domain name, i.e. sitename.stitchz.net
Description string A short description of the application
ApplicationType string The name of the application type this application is currently setup with
DnsAlias string This is the URL you use when setting up your site with one of the authentication providers. This will also be the URL users will see when logging in with one of your providers.
Domain string The domain name for your web site, for example, yourdomain.com
Favicon string The app's website favicon.
RequestUserEmailFromProviders boolean Whether or not the application want's to collect email from the identity login provider upon user authentication.
UseGetFormMethodRequest boolean Whether or not the appplication requires a GET form method request.
ReturnUrl url The Return URL should be ready to accept a POST from Stitchz Login with a one time unique key
PrivacyUrl url The URL to your applications Privacy statement
ApiKey string The unique Application key. This is an automatically assigned number that identifies the application.
WhiteListUrls string Comma separated list of domains. Stitchz will only accept requests from one of these domains.
Members string A collection of application members
Username string Child of Member, username of the member
Email string Child of Member, email address of the member
IsOwner boolean Child of Member, whether or not this member is the application owner
DisplayName string Child of Member, the displayname of the member
Identifier string Child of Member, the unique identifier of the member
 
* all fields are always returned in the response.
 
Example XML Response
Example JSON Response
<ApplicationSettings xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Stitchz.Api.Models">
    <ApiKey>000000000000</ApiKey>
    <Description></Description>
    <ApplicationType>basic</ApplicationType>
    <DnsAlias>login.stitchz.net</DnsAlias>
    <Domain>stitchz.net</Domain>
    <Favicon>http://www.stitchz.net/Content/images/favicon.png</Favicon>
    <Members>
        <ApplicationMember>
            <DisplayName>Stitchz Communications</DisplayName>
            <Email>stitchzdotnet@gmail.com</Email>
            <Identifier>https://profiles.google.com/000000000000000000000000000000000</Identifier>
            <IsOwner>true</IsOwner>
            <Username>stitchzdotnet@gmail.com</Username>
        </ApplicationMember>
    </Members>
    <Name>Stitchz</Name>
    <PrivacyUrl>http://www.stitchz.net/Privacy</PrivacyUrl>
    <RequestUserEmailFromProviders>false</RequestUserEmailFromProviders>
    <ReturnUrl>https://login.stitchz.net/Account/ProviderAuthorization</ReturnUrl>
    <UseGetFormMethodRequest>false</UseGetFormMethodRequest>
    <WhiteListUrls>localhost, login.stitchz.net</WhiteListUrls>
</ApplicationSettings>
{
    "Name": "Stitchz",
    "Description": "This is the application description",
    "ApplicationType": "basic",
    "Domain": "stitchz.net",
    "ReturnUrl": "https://login.stitchz.net/Account/ProviderAuthorization",
    "PrivacyUrl": "https://stitchz.net/Privacy",
    "WhiteListUrls": "localhost, login.stitchz.net, www.stitchz.net",
    "Favicon": "http://www.stitchz.net/Content/images/favicon.png",
    "RequestUserEmailFromProviders": false,
    "UseGetFormMethodRequest": false,
    "DnsAlias": "login.stitchz.net",
    "ApiKey": "000000000000",
    "Members": [{
        "Username": "[email protected]",
        "IsOwner": true
        "Email": "[email protected]"
        "DisplayName": "Stitchz Communications",
        "Identifier": "https://profiles.google.com/0000000000000000000000000"
    }]
}
Request Type
PATCH
 
Updates the application's settings as defined on the Stitchz Login Settings page. Include only those fields/values to be updated in the request. No user identity string required.
 
Example URL
https://login.stitchz.net/api/v2/settings
 
Request
Required Parameter Type Description
yes Bearer string The application's unique Oauth2 bearer token (access token) in the request header
  Format string The format of the authenticated Stitchz response, XML, JSON, JSONP. A query string parameter can be included in the request (e.g. ?format=json) or a header variable of "Accept" with the proper value, e.g. 'application/json', 'application/xml', etc. The default response is in "JSON" format.
 
Example JSON Response
Example JSON Response
Example Form-Urlencoded Response
Content-Type: 'application/xml'

<ApplicationSettings xmlns="http://schemas.datacontract.org/2004/07/Stitchz.Api.Models">
    <Name>Stitchz</Name>
    <Description>This is the application description</Description>
    <Domain>stitchz.net</Domain>
    <ReturnUrl>https://login.stitchz.net/Account/ProviderAuthorization</ReturnUrl>
    <PrivacyUrl>http://www.stitchz.net/Privacy</PrivacyUrl>
    <WhiteListUrls>localhost, login.stitchz.net</WhiteListUrls>
    <Favicon>http://www.stitchz.net/Content/images/favicon.png</Favicon>
    <RequestUserEmailFromProviders>false</RequestUserEmailFromProviders>
    <UseGetFormMethodRequest>false</UseGetFormMethodRequest>
</ApplicationSettings>
Content-Type: 'application/json'

{
    "Name": "Stitchz",
    "Description": "This is the application description",
    "Domain": "stitchz.net",
    "ReturnUrl": "https://login.stitchz.net/Account/ProviderAuthorization",
    "PrivacyUrl": "https://stitchz.net/Privacy",
    "WhiteListUrls": "localhost, login.stitchz.net, www.stitchz.net",
    "Favicon": "http://www.stitchz.net/Content/images/favicon.png",
    "RequestUserEmailFromProviders": false,
    "UseGetFormMethodRequest": false,
}
Content-Type: 'application/x-www-form-urlencoded'

Name=Stitchz&Description=This is the application description&Domain=stitchz.net&ReturnUrl=https://login.stitchz.net/Account/ProviderAuthorization&PrivacyUrl=http://www.stitchz.net/Privacy&WhiteListUrls=localhost, login.stitchz.net&Favicon=http://www.stitchz.net/Content/images/favicon.png&RequestUserEmailFromProviders=false&UseGetFormMethodRequest=false
 
Response
 
* all fields are always returned in the response. See the table in the Get Response above for details in each field returned.
 
Example XML Response
Example JSON Response
<ApplicationSettings xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Stitchz.Api.Models">
    <ApiKey>000000000000</ApiKey>
    <Description></Description>
    <ApplicationType>basic</ApplicationType>
    <DnsAlias>login.stitchz.net</DnsAlias>
    <Domain>stitchz.net</Domain>
    <Favicon>http://www.stitchz.net/Content/images/favicon.png</Favicon>
    <Members>
        <ApplicationMember>
            <DisplayName>Stitchz Communications</DisplayName>
            <Email>stitchzdotnet@gmail.com</Email>
            <Identifier>https://profiles.google.com/000000000000000000000000000000000</Identifier>
            <IsOwner>true</IsOwner>
            <Username>stitchzdotnet@gmail.com</Username>
        </ApplicationMember>
    </Members>
    <Name>Stitchz</Name>
    <PrivacyUrl>http://www.stitchz.net/Privacy</PrivacyUrl>
    <RequestUserEmailFromProviders>false</RequestUserEmailFromProviders>
    <ReturnUrl>https://login.stitchz.net/Account/ProviderAuthorization</ReturnUrl>
    <UseGetFormMethodRequest>false</UseGetFormMethodRequest>
    <WhiteListUrls>localhost, login.stitchz.net</WhiteListUrls>
</ApplicationSettings>
{
    "Name": "Stitchz",
    "Description": "This is the application description",
    "ApplicationType": "basic",
    "Domain": "stitchz.net",
    "Url": "https://login.stitchz.net/Account/ProviderAuthorization",
    "PrivacyUrl": "https://stitchz.net/Privacy",
    "WhiteListUrls": "localhost, login.stitchz.net, www.stitchz.net",
    "Favicon": "http://www.stitchz.net/Content/images/favicon.png",
    "RequestUserEmailFromProviders": false,
    "UseGetFormMethodRequest": false,
    "DnsAlias": "login.stitchz.net",
    "ApiKey": "000000000000",
    "Members": [{
        "Username": "[email protected]",
        "IsOwner": true
        "Email": "[email protected]"
        "DisplayName": "Stitchz Communications",
        "Identifier": "https://profiles.google.com/0000000000000000000000000"
    }]
}