Junos Space SDK > Developer Guides > Application Developer Guide > Programming with the Junos Space SDK > Using the Junos Space SDK Plug-in > Using the EJB-REST Wizard > REST Wizard Documentation Guide

REST API Resource Model

Introduction

Media Type Index


Resource Model Tables

Country (vnd.jssdk.hello-world.hello-world.country;version=1)

A model object which represents a country. A member of the countries primary collection. (DTO page, Documentation panel)

Field Name Type Occurs Description GET PUT/POST
@uri String(URI) 0 Link to this Country node in the current node context. For primary collection members, href and uri are always the same.

Hyperlink Template: /api/jssdk/hello-world/hello-world/countries/{country-id}
Y N
@href String(URI) 0 Link to an external Country. Here, href points to the Country in the primary Countries collection.

Hyperlink Template: /api/jssdk/hello-world/hello-world/countries/{id}
Y N
*id int 0   Y N
name String 1 name of the country (Edit DTO Field Description dialog) Y Y
population Integer 1   Y Y
states Country.states 0 collection of the country's states (Nested DTO page, Documentation panel) Y N
get-capital String 0 returns the country's capital (Configure Method dialog) Y N

Country.states

collection of the country's states (Nested DTO page, Documentation panel)

Field Name Type Occurs Description GET PUT/POST
@uri String(URI) 0 Link to this Country.states node in the current node context. This link can be used to retrieve or operate on the currently referenced Country.states in the tree path.

Hyperlink Template: /api/jssdk/hello-world/hello-world/countries/{country-id}/states
Y N
state Country.states.state[] 1..N
Y Y

Country.states.state
Field Name Type Occurs Description GET PUT/POST Sort Filter
@uri String(URI) 0 Link to this Country.states.state node in the current node context. This link can be used to retrieve or operate on the currently referenced Country.states.state in the tree path.

Hyperlink Template: /api/jssdk/hello-world/hello-world/countries/{country-id}/states/{id}
Y N N N
@href String(URI) 1 Link to an external State. Here, href points to the State in the primary States collection.

Hyperlink Template: /api/jssdk/hello-world/hello-world/states/{id}
Y Y N N
id int 0   Y N Y Y
name String 0   Y N Y Y

Deprecated

This section lists all deprecated media types.