Requires the role: | superadmin |
PUT | /superadmin/support/cases/{Id} | Update a support case | Update a support case to the company of the currently logged in user, only administrators are allowed to add support cases. |
---|
export class SupportCaseStatusResponse
{
/** @description The status id */
// @ApiMember(Description="The status id")
public Id: number;
/** @description The status name */
// @ApiMember(Description="The status name")
public Name: string;
/** @description The status description */
// @ApiMember(Description="The status description")
public Description: string;
/** @description The status icon */
// @ApiMember(Description="The status icon")
public Icon: string;
/** @description The status color */
// @ApiMember(Description="The status color")
public Color: string;
public constructor(init?: Partial<SupportCaseStatusResponse>) { (Object as any).assign(this, init); }
}
export class SupportCaseTypeResponse
{
/** @description The type id */
// @ApiMember(Description="The type id")
public Id: number;
/** @description The type name */
// @ApiMember(Description="The type name")
public Name: string;
/** @description The type description */
// @ApiMember(Description="The type description")
public Description: string;
public constructor(init?: Partial<SupportCaseTypeResponse>) { (Object as any).assign(this, init); }
}
export class SupportCaseAreaResponse
{
/** @description The area id */
// @ApiMember(Description="The area id")
public Id: number;
/** @description The area name */
// @ApiMember(Description="The area name")
public Name: string;
/** @description The area description */
// @ApiMember(Description="The area description")
public Description: string;
public constructor(init?: Partial<SupportCaseAreaResponse>) { (Object as any).assign(this, init); }
}
export class SupportCaseCommentsResponse
{
/** @description The case id */
// @ApiMember(Description="The case id")
public SupportCaseId: number;
/** @description The comments id */
// @ApiMember(Description="The comments id")
public Id: number;
/** @description The case comment */
// @ApiMember(Description="The case comment")
public Comment: string;
/** @description The case comment created by */
// @ApiMember(Description="The case comment created by")
public CreatedBy: string;
/** @description The case comment created date */
// @ApiMember(Description="The case comment created date")
public Created: string;
public constructor(init?: Partial<SupportCaseCommentsResponse>) { (Object as any).assign(this, init); }
}
export class SupportCaseAttachmentResponse
{
/** @description The attachment id */
// @ApiMember(Description="The attachment id")
public Id: number;
/** @description The attachment file url */
// @ApiMember(Description="The attachment file url")
public FileUrl: string;
public constructor(init?: Partial<SupportCaseAttachmentResponse>) { (Object as any).assign(this, init); }
}
export class SupportCaseQueryResponse
{
/** @description The support case id */
// @ApiMember(Description="The support case id")
public Id: number;
/** @description The company user id */
// @ApiMember(Description="The company user id")
public CompanyUserId: string;
/** @description The case title. */
// @ApiMember(Description="The case title.")
public Title: string;
/** @description The case description. */
// @ApiMember(Description="The case description.")
public Description: string;
/** @description The case status id. */
// @ApiMember(Description="The case status id.")
public CaseStatusId: number;
/** @description If the case type id. */
// @ApiMember(Description="If the case type id.")
public CaseTypeId: number;
/** @description If the case area id. */
// @ApiMember(Description="If the case area id.")
public CaseAreaId: number;
/** @description The case created by. */
// @ApiMember(Description="The case created by.")
public CreatedBy: string;
/** @description The case updated by. */
// @ApiMember(Description="The case updated by.")
public UpdatedBy: string;
/** @description The case solved by. */
// @ApiMember(Description="The case solved by.")
public SolvedBy: string;
/** @description If case updated date. */
// @ApiMember(Description="If case updated date.")
public Updated: string;
/** @description If case created date. */
// @ApiMember(Description="If case created date.")
public Created: string;
/** @description Who owns the support case. */
// @ApiMember(Description="Who owns the support case.")
public CaseOwner: string;
/** @description The case status information. */
// @ApiMember(Description="The case status information.")
public CaseStatus: SupportCaseStatusResponse;
/** @description The case type information. */
// @ApiMember(Description="The case type information.")
public CaseType: SupportCaseTypeResponse;
/** @description The case area information. */
// @ApiMember(Description="The case area information.")
public CaseArea: SupportCaseAreaResponse;
/** @description The case comments. */
// @ApiMember(Description="The case comments.")
public Comments: SupportCaseCommentsResponse[];
/** @description The case attachments. */
// @ApiMember(Description="The case attachments.")
public Attachments: SupportCaseAttachmentResponse[];
/** @description The case status options to select from. */
// @ApiMember(Description="The case status options to select from.")
public CaseStatusOptions: SupportCaseStatusResponse[];
/** @description The case type options to select from. */
// @ApiMember(Description="The case type options to select from.")
public CaseTypeOptions: SupportCaseTypeResponse[];
/** @description The case area options to select from. */
// @ApiMember(Description="The case area options to select from.")
public CaseAreaOptions: SupportCaseAreaResponse[];
public constructor(init?: Partial<SupportCaseQueryResponse>) { (Object as any).assign(this, init); }
}
// @ApiResponse(Description="You were unauthorized to call this service", StatusCode=401)
// @ApiResponse(Description="You have too low privilegies to call this service", StatusCode=403)
// @ValidateRequest(Validator="IsAuthenticated")
export class SuperAdminUpdateSupportCase implements ISupportCase
{
/** @description Enter the company id, if blank company id and you are an admin, your company id will be used. */
// @ApiMember(Description="Enter the company id, if blank company id and you are an admin, your company id will be used.", IsRequired=true)
public CompanyId: string;
/** @description The support case id */
// @ApiMember(Description="The support case id", ParameterType="path")
public Id: number;
/** @description The case title. */
// @ApiMember(Description="The case title.")
public Title: string;
/** @description The case description. */
// @ApiMember(Description="The case description.")
public Description: string;
/** @description If the case type id. */
// @ApiMember(Description="If the case type id.")
public CaseTypeId?: number;
/** @description If the case area id. */
// @ApiMember(Description="If the case area id.")
public CaseAreaId?: number;
public constructor(init?: Partial<SuperAdminUpdateSupportCase>) { (Object as any).assign(this, init); }
}
TypeScript SuperAdminUpdateSupportCase DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
PUT /superadmin/support/cases/{Id} HTTP/1.1
Host: api.bokamera.se
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<SuperAdminUpdateSupportCase xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos">
<CaseAreaId>0</CaseAreaId>
<CaseTypeId>0</CaseTypeId>
<CompanyId>00000000-0000-0000-0000-000000000000</CompanyId>
<Description>String</Description>
<Id>0</Id>
<Title>String</Title>
</SuperAdminUpdateSupportCase>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <SupportCaseQueryResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos"> <Attachments> <SupportCaseAttachmentResponse> <FileUrl>String</FileUrl> <Id>0</Id> </SupportCaseAttachmentResponse> </Attachments> <CaseArea> <Description>String</Description> <Id>0</Id> <Name>String</Name> </CaseArea> <CaseAreaId>0</CaseAreaId> <CaseAreaOptions> <SupportCaseAreaResponse> <Description>String</Description> <Id>0</Id> <Name>String</Name> </SupportCaseAreaResponse> </CaseAreaOptions> <CaseOwner>String</CaseOwner> <CaseStatus> <Color>String</Color> <Description>String</Description> <Icon>String</Icon> <Id>0</Id> <Name>String</Name> </CaseStatus> <CaseStatusId>0</CaseStatusId> <CaseStatusOptions> <SupportCaseStatusResponse> <Color>String</Color> <Description>String</Description> <Icon>String</Icon> <Id>0</Id> <Name>String</Name> </SupportCaseStatusResponse> </CaseStatusOptions> <CaseType> <Description>String</Description> <Id>0</Id> <Name>String</Name> </CaseType> <CaseTypeId>0</CaseTypeId> <CaseTypeOptions> <SupportCaseTypeResponse> <Description>String</Description> <Id>0</Id> <Name>String</Name> </SupportCaseTypeResponse> </CaseTypeOptions> <Comments> <SupportCaseCommentsResponse> <Comment>String</Comment> <Created>0001-01-01T00:00:00</Created> <CreatedBy>String</CreatedBy> <Id>0</Id> <SupportCaseId>0</SupportCaseId> </SupportCaseCommentsResponse> </Comments> <CompanyUserId>00000000-0000-0000-0000-000000000000</CompanyUserId> <Created>0001-01-01T00:00:00</Created> <CreatedBy>String</CreatedBy> <Description>String</Description> <Id>0</Id> <SolvedBy>String</SolvedBy> <Title>String</Title> <Updated>0001-01-01T00:00:00</Updated> <UpdatedBy>String</UpdatedBy> </SupportCaseQueryResponse>