Skip to content

ARLAS Subscriptions Manager API vAPI_VERSION

Scroll down for example requests and responses.

Manage ARLAS subscriptions on ARLAS collections' events.

Base URLs:

Email: Gisaia Web: Gisaia License: Apache 2.0

admin

Optional endpoints to manage all subscriptions as an administrator of the service.

Find subscription by ID

GET /admin/subscriptions/{id}

Return a single subscription. Only creator can access their subscriptions.

Parameters

Name In Type Required Description
id path string true ID of subscription to return
deleted query boolean false Filter subscriptions whether they are deleted or not.
pretty query boolean false Pretty print

Example responses

200 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
200 OK Successful operation UserSubscriptionWithLinks
401 Unauthorized Unauthorized. Error
404 Not Found Subscription not found. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

Update an existing subscription

PUT /admin/subscriptions/{id}

Update an existing subscription.

Body parameter

{
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  }
}

Parameters

Name In Type Required Description
id path string true ID of subscription to return
pretty query boolean false Pretty print
body body UserSubscription true Subscription description

Example responses

201 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
201 Created Successful operation UserSubscriptionWithLinks
400 Bad Request JSON parameter malformed. Error
401 Unauthorized Unauthorized. Error
404 Not Found Not Found Error. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

Delete a subscription

DELETE /admin/subscriptions/{id}

Mark a subscription as deleted.

Parameters

Name In Type Required Description
id path string true Subscription ID to delete
pretty query boolean false Pretty print

Example responses

202 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
202 Accepted Subscription has been deleted. UserSubscriptionWithLinks
401 Unauthorized Unauthorized. Error
404 Not Found Subscription not found. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

List all available subscriptions

GET /admin/subscriptions

Return the list of all registered subscriptions from the latest created to the earliest.

Parameters

Name In Type Required Description
before query integer(int64) false Retrieve subscriptions created before given timestamp.
after query integer(int64) false Retrieve subscriptions created after given timestamp.
active query boolean false Filter subscriptions whether they are active or not (returns all if missing, 'active' if 'true', 'not active' if 'false').
started query boolean false Filter subscriptions whether they are started or not (returns all if missing, 'started' if 'true', 'not started' if 'false').
expired query boolean false Filter subscriptions whether they are expired or not (returns all if missing, 'expired' if 'true', 'not expired' if 'false').
created-by query string false Filter subscriptions by creator's identifier
deleted query boolean false Filter subscriptions whether they are deleted or not.
created-by-admin query boolean false Filter subscriptions whether they have been created by admin or not (returns all if missing, 'created_by_admin' if 'true', 'not created_by_admin' if 'false').
pretty query boolean false Pretty print
page query integer(int64) false Page ID
size query integer(int64) false Page Size

Example responses

200 Response

{
  "count": 0,
  "total": 0,
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  },
  "subscriptions": [
    {
      "id": "string",
      "created_at": 0,
      "modified_at": 0,
      "created_by_admin": true,
      "deleted": true,
      "created_by": "string",
      "active": true,
      "starts_at": 0,
      "expires_at": 0,
      "title": "string",
      "subscription": {
        "trigger": {
          "property1": {},
          "property2": {}
        },
        "callback": "string",
        "hits": {
          "filter": "string",
          "projection": "string"
        }
      },
      "userMetadatas": {
        "property1": {},
        "property2": {}
      },
      "_links": {
        "property1": {
          "relation": "string",
          "href": "string",
          "type": "string",
          "method": "string"
        },
        "property2": {
          "relation": "string",
          "href": "string",
          "type": "string",
          "method": "string"
        }
      }
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK Successful operation SubscriptionListResource
401 Unauthorized Unauthorized. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

Register a new subscription

POST /admin/subscriptions

Register a subscription for further notification.

Body parameter

{
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  }
}

Parameters

Name In Type Required Description
pretty query boolean false Pretty print
body body UserSubscription true Subscription description

Example responses

201 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
201 Created Subscription has been registered UserSubscriptionWithLinks
400 Bad Request JSON parameter malformed. Error
401 Unauthorized Unauthorized. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

end-user

Standard endpoints to manage one's subscriptions as an end-user.

Find subscription by ID

GET /subscriptions/{id}

Return a single subscription. Only creator can access their subscriptions.

Parameters

Name In Type Required Description
id path string true ID of subscription to return
pretty query boolean false Pretty print

Example responses

200 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
200 OK Successful operation UserSubscriptionWithLinks
401 Unauthorized Unauthorized. Error
403 Forbidden Forbidden. Error
404 Not Found Subscription not found. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

Update an existing subscription

PUT /subscriptions/{id}

Update an existing subscription. Only creator can update their own subscriptions.

Body parameter

{
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  }
}

Parameters

Name In Type Required Description
id path string true ID of subscription to return
pretty query boolean false Pretty print
body body UserSubscription true Subscription description

Example responses

201 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
201 Created Successful operation UserSubscriptionWithLinks
400 Bad Request JSON parameter malformed. Error
401 Unauthorized Unauthorized. Error
403 Forbidden Forbidden. Error
404 Not Found Not Found Error. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

Delete a subscription

DELETE /subscriptions/{id}

Mark a subscription as deleted. Only creator can delete their own subscriptions.

Parameters

Name In Type Required Description
id path string true Subscription ID to delete
pretty query boolean false Pretty print

Example responses

202 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
202 Accepted Subscription has been deleted. UserSubscriptionWithLinks
401 Unauthorized Unauthorized. Error
403 Forbidden Forbidden. Error
404 Not Found Subscription not found. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

List all available subscriptions

GET /subscriptions

Return the list of all registered subscriptions that are available for current user from the latest created to the earliest. Only current user's subscriptions that are not deleted are listed.

Parameters

Name In Type Required Description
before query integer(int64) false Retrieve subscriptions created before given timestamp.
active query boolean false Filter subscriptions whether they are active or not (returns all if missing, 'active' if 'true', 'inactive' if 'false').
expired query boolean false Filter subscriptions whether they are expired or not (returns all if missing, 'expired' if 'true', 'not expired' if 'false').
pretty query boolean false Pretty print
size query integer(int64) false Page Size
page query integer(int64) false Page ID

Example responses

200 Response

{
  "count": 0,
  "total": 0,
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  },
  "subscriptions": [
    {
      "id": "string",
      "created_at": 0,
      "modified_at": 0,
      "created_by_admin": true,
      "deleted": true,
      "created_by": "string",
      "active": true,
      "starts_at": 0,
      "expires_at": 0,
      "title": "string",
      "subscription": {
        "trigger": {
          "property1": {},
          "property2": {}
        },
        "callback": "string",
        "hits": {
          "filter": "string",
          "projection": "string"
        }
      },
      "userMetadatas": {
        "property1": {},
        "property2": {}
      },
      "_links": {
        "property1": {
          "relation": "string",
          "href": "string",
          "type": "string",
          "method": "string"
        },
        "property2": {
          "relation": "string",
          "href": "string",
          "type": "string",
          "method": "string"
        }
      }
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK Successful operation SubscriptionListResource
401 Unauthorized Unauthorized. Error
403 Forbidden Forbidden. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

Register a new subscription

POST /subscriptions

Register a subscription for further notification.

Body parameter

{
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  }
}

Parameters

Name In Type Required Description
pretty query boolean false Pretty print
body body UserSubscription true Subscription description

Example responses

201 Response

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Responses

Status Meaning Description Schema
201 Created Subscription has been registered UserSubscriptionWithLinks
400 Bad Request JSON parameter malformed. Error
401 Unauthorized Unauthorized. Error
403 Forbidden Forbidden. Error
404 Not Found Not Found Error. Error
503 Service Unavailable Arlas Subscriptions Manager Error. Error

Schemas

Hits

{
  "filter": "string",
  "projection": "string"
}

Properties

Name Type Required Restrictions Description
filter string true none none
projection string true none none

{
  "relation": "string",
  "href": "string",
  "type": "string",
  "method": "string"
}

Properties

Name Type Required Restrictions Description
relation string true none none
href string true none none
type string true none none
method string true none none

Subscription

{
  "trigger": {
    "property1": {},
    "property2": {}
  },
  "callback": "string",
  "hits": {
    "filter": "string",
    "projection": "string"
  }
}

Properties

Name Type Required Restrictions Description
trigger object true none none
» additionalProperties object false none none
callback string true none none
hits Hits true none none

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  },
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  }
}

Properties

Name Type Required Restrictions Description
id string false read-only none
created_at integer(int64) false read-only none
modified_at integer(int64) false read-only none
created_by_admin boolean false read-only none
deleted boolean false read-only none
created_by string true none none
active boolean true none none
starts_at integer(int64) true none none
expires_at integer(int64) true none none
title string true none none
subscription Subscription true none none
userMetadatas object false none none
» additionalProperties object false none none
_links object false none none
» additionalProperties Link false none none

Error

{
  "status": 0,
  "message": "string",
  "error": "string"
}

Properties

Name Type Required Restrictions Description
status integer(int32) false none none
message string false none none
error string false none none

SubscriptionListResource

{
  "count": 0,
  "total": 0,
  "_links": {
    "property1": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    },
    "property2": {
      "relation": "string",
      "href": "string",
      "type": "string",
      "method": "string"
    }
  },
  "subscriptions": [
    {
      "id": "string",
      "created_at": 0,
      "modified_at": 0,
      "created_by_admin": true,
      "deleted": true,
      "created_by": "string",
      "active": true,
      "starts_at": 0,
      "expires_at": 0,
      "title": "string",
      "subscription": {
        "trigger": {
          "property1": {},
          "property2": {}
        },
        "callback": "string",
        "hits": {
          "filter": "string",
          "projection": "string"
        }
      },
      "userMetadatas": {
        "property1": {},
        "property2": {}
      },
      "_links": {
        "property1": {
          "relation": "string",
          "href": "string",
          "type": "string",
          "method": "string"
        },
        "property2": {
          "relation": "string",
          "href": "string",
          "type": "string",
          "method": "string"
        }
      }
    }
  ]
}

Properties

Name Type Required Restrictions Description
count integer(int32) false none none
total integer(int32) false none none
_links object false none none
» additionalProperties Link false none none
subscriptions [UserSubscriptionWithLinks] false none none

UserSubscription

{
  "id": "string",
  "created_at": 0,
  "modified_at": 0,
  "created_by_admin": true,
  "deleted": true,
  "created_by": "string",
  "active": true,
  "starts_at": 0,
  "expires_at": 0,
  "title": "string",
  "subscription": {
    "trigger": {
      "property1": {},
      "property2": {}
    },
    "callback": "string",
    "hits": {
      "filter": "string",
      "projection": "string"
    }
  },
  "userMetadatas": {
    "property1": {},
    "property2": {}
  }
}

Properties

Name Type Required Restrictions Description
id string false read-only none
created_at integer(int64) false read-only none
modified_at integer(int64) false read-only none
created_by_admin boolean false read-only none
deleted boolean false read-only none
created_by string true none none
active boolean true none none
starts_at integer(int64) true none none
expires_at integer(int64) true none none
title string true none none
subscription Subscription true none none
userMetadatas object false none none
» additionalProperties object false none none