| GET,OPTIONS | /v1/weather/branch |
|---|
namespace CRM.AgencyPlatform.API.Internal
open System
open System.IO
open System.Collections
open System.Collections.Generic
open System.Runtime.Serialization
open ServiceStack
open ServiceStack.DataAnnotations
[<AllowNullLiteral>]
type WeatherDay() =
member val Date:String = null with get,set
member val DayLabel:String = null with get,set
member val ShortForecast:String = null with get,set
member val TempHi:Nullable<Int32> = new Nullable<Int32>() with get,set
member val TempLo:Nullable<Int32> = new Nullable<Int32>() with get,set
member val TempUnit:String = null with get,set
member val Pop:Nullable<Int32> = new Nullable<Int32>() with get,set
member val Severity:String = null with get,set
member val HasAlert:Boolean = new Boolean() with get,set
[<AllowNullLiteral>]
type WeatherForecastResponse() =
member val BranchName:String = null with get,set
member val Resolved:Boolean = new Boolean() with get,set
member val AlertHeadline:String = null with get,set
member val Days:ResizeArray<WeatherDay> = new ResizeArray<WeatherDay>() with get,set
member val ResponseStatus:ResponseStatus = null with get,set
[<AllowNullLiteral>]
type BranchWeatherRequest() =
member val BranchId:Nullable<Guid> = new Nullable<Guid>() with get,set
member val Start:String = null with get,set
member val Days:Nullable<Int32> = new Nullable<Int32>() with get,set
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /v1/weather/branch HTTP/1.1 Host: api.dev.dynamics.trendsic.com Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
BranchName: String,
Resolved: False,
AlertHeadline: String,
Days:
[
{
Date: String,
DayLabel: String,
ShortForecast: String,
TempHi: 0,
TempLo: 0,
TempUnit: String,
Pop: 0,
Severity: String,
HasAlert: False
}
],
ResponseStatus:
{
ErrorCode: String,
Message: String,
StackTrace: String,
Errors:
[
{
ErrorCode: String,
FieldName: String,
Message: String,
Meta:
{
String: String
}
}
],
Meta:
{
String: String
}
}
}