Trendsic Platform Service

<back to all web services

BranchWeatherRequest

Requires Authentication
The following routes are available for this service:
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

F# BranchWeatherRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other

HTTP + OTHER

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/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
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"}}}