Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 149 lines (99 sloc) 3.34 KB

ArticlesApi

All URIs are relative to http://hytale.com/api

Method HTTP request Description
getArticleBySlug GET /blog/post/slug/{slug}
getArticles GET /blog/post/published
getArticlesOfMonthAndYear GET /blog/post/archive/{year}/{month}/

getArticleBySlug

Article getArticleBySlug(slug)

Get list of articles published

Example

// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.ArticlesApi;


ArticlesApi apiInstance = new ArticlesApi();
String slug = "slug_example"; // String | Slug of article
try {
    Article result = apiInstance.getArticleBySlug(slug);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling ArticlesApi#getArticleBySlug");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
slug String Slug of article

Return type

Article

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

getArticles

List<Article> getArticles(featuredOnly)

Get list of articles published

Example

// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.ArticlesApi;


ArticlesApi apiInstance = new ArticlesApi();
Boolean featuredOnly = true; // Boolean | 
try {
    List<Article> result = apiInstance.getArticles(featuredOnly);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling ArticlesApi#getArticles");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
featuredOnly Boolean [optional]

Return type

List<Article>

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

getArticlesOfMonthAndYear

List<Article> getArticlesOfMonthAndYear(year, month)

Get list of articles published on a specific month of an year

Example

// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.ArticlesApi;


ArticlesApi apiInstance = new ArticlesApi();
Integer year = 56; // Integer | Year (ex: 2019)
Integer month = 56; // Integer | Month (ex: 01)
try {
    List<Article> result = apiInstance.getArticlesOfMonthAndYear(year, month);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling ArticlesApi#getArticlesOfMonthAndYear");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
year Integer Year (ex: 2019)
month Integer Month (ex: 01)

Return type

List<Article>

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json
You can’t perform that action at this time.