MyApp

<back to all web services

UpdatePhoneScreen

Talent
Requires Authentication
const std = @import("std");

pub const AppUser = struct {
    id: ?[]const u8 = null,
    firstName: ?[]const u8 = null,
    lastName: ?[]const u8 = null,
    displayName: ?[]const u8 = null,
    profileUrl: ?[]const u8 = null,
};

pub const JobApplicationStatus = enum {
    Applied,
    PhoneScreening,
    PhoneScreeningCompleted,
    Interview,
    InterviewCompleted,
    Offer,
    Disqualified,
};

pub const PhoneScreen = struct {
    // @DataMember(Order=1)
    createdDate: ?[]const u8 = null,

    // @DataMember(Order=2)
    // @Required()
    createdBy: ?[]const u8 = null,

    // @DataMember(Order=3)
    modifiedDate: ?[]const u8 = null,

    // @DataMember(Order=4)
    // @Required()
    modifiedBy: ?[]const u8 = null,

    // @DataMember(Order=5)
    deletedDate: ?[]const u8 = null,

    // @DataMember(Order=6)
    deletedBy: ?[]const u8 = null,
    id: i32 = 0,
    // @References(typeof(AppUser))
    appUserId: ?[]const u8 = null,

    appUser: ?AppUser = null,
    // @References(typeof(JobApplication))
    jobApplicationId: i32 = 0,

    applicationStatus: ?JobApplicationStatus = null,
    notes: ?[]const u8 = null,
};

// @ValidateRequest(Validator="IsAuthenticated")
pub const UpdatePhoneScreen = struct {
    id: i32 = 0,
    jobApplicationId: ?i32 = null,
    notes: ?[]const u8 = null,
    applicationStatus: ?JobApplicationStatus = null,
};

Zig UpdatePhoneScreen DTOs

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

HTTP + JSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /jsv/reply/UpdatePhoneScreen HTTP/1.1 
Host: blazor-gallery.servicestack.net 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	id: 0,
	jobApplicationId: 0,
	notes: String,
	applicationStatus: Applied
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	id: 0,
	appUserId: String,
	appUser: 
	{
		id: String,
		firstName: String,
		lastName: String,
		displayName: String,
		profileUrl: String
	},
	jobApplicationId: 0,
	applicationStatus: Applied,
	notes: String,
	createdDate: 0001-01-01,
	createdBy: String,
	modifiedDate: 0001-01-01,
	modifiedBy: String,
	deletedDate: 0001-01-01,
	deletedBy: String
}