POST api/News/Search

Search news

Request Information

URI Parameters

None.

Body Parameters

NewsSearchFilter
NameDescriptionTypeAdditional information
SearchText

string

None.

CompanyIds

Collection of integer

None.

NewsGroupTypeIds

Collection of integer

None.

StartDate

date

None.

EndDate

date

None.

PageSize

integer

None.

CurrentPage

integer

None.

SortBy

string

None.

SortType

string

None.

Request Formats

application/json, text/json

Sample:
{
  "SearchText": "sample string 1",
  "CompanyIds": [
    1,
    2
  ],
  "NewsGroupTypeIds": [
    1,
    2
  ],
  "StartDate": "2026-04-01T10:16:30.627966+07:00",
  "EndDate": "2026-04-01T10:16:30.627966+07:00",
  "PageSize": 2,
  "CurrentPage": 3,
  "SortBy": "sample string 4",
  "SortType": "sample string 5"
}

text/html

Sample:
{"SearchText":"sample string 1","CompanyIds":[1,2],"NewsGroupTypeIds":[1,2],"StartDate":"2026-04-01T10:16:30.627966+07:00","EndDate":"2026-04-01T10:16:30.627966+07:00","PageSize":2,"CurrentPage":3,"SortBy":"sample string 4","SortType":"sample string 5"}

application/xml, text/xml

Sample:
<NewsSearchFilter xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TTMWM_MECLAIM_API.ViewModels">
  <CompanyIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>1</d2p1:int>
    <d2p1:int>2</d2p1:int>
  </CompanyIds>
  <CurrentPage>3</CurrentPage>
  <EndDate>2026-04-01T10:16:30.627966+07:00</EndDate>
  <NewsGroupTypeIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>1</d2p1:int>
    <d2p1:int>2</d2p1:int>
  </NewsGroupTypeIds>
  <PageSize>2</PageSize>
  <SearchText>sample string 1</SearchText>
  <SortBy>sample string 4</SortBy>
  <SortType>sample string 5</SortType>
  <StartDate>2026-04-01T10:16:30.627966+07:00</StartDate>
</NewsSearchFilter>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

List of news

ServiceResultTypedOfNewsSearchResult
NameDescriptionTypeAdditional information
Code

integer

None.

Errors

Collection of string

None.

Data

NewsSearchResult

None.

Response Formats

application/json, text/json

Sample:
{
  "Code": 1,
  "Errors": [
    "sample string 1",
    "sample string 2"
  ],
  "Data": {
    "TotalRows": 1,
    "NewsList": [
      {
        "Id": 1,
        "CreatedDate": "2026-04-01T10:16:30.6339553+07:00",
        "CreatedDateStr": "sample string 3",
        "UpdatedDate": "2026-04-01T10:16:30.6339553+07:00",
        "UpdatedDateStr": "sample string 5",
        "Title": "sample string 6",
        "HeaderImageId": 1,
        "Content": "sample string 7",
        "StartDate": "2026-04-01T10:16:30.6339553+07:00",
        "StartDateStr": "sample string 9",
        "EndDate": "2026-04-01T10:16:30.6339553+07:00",
        "EndDateStr": "sample string 11",
        "NewsGroupTypeId": 12,
        "Url": "sample string 13",
        "OnTop": 14,
        "HeaderImageName": "sample string 15",
        "HeaderImageUrl": "sample string 16",
        "CompanyIds": [
          1,
          2
        ],
        "NewsGroupTypeName": "sample string 17",
        "EmployeeCompanyId": 1
      },
      {
        "Id": 1,
        "CreatedDate": "2026-04-01T10:16:30.6339553+07:00",
        "CreatedDateStr": "sample string 3",
        "UpdatedDate": "2026-04-01T10:16:30.6339553+07:00",
        "UpdatedDateStr": "sample string 5",
        "Title": "sample string 6",
        "HeaderImageId": 1,
        "Content": "sample string 7",
        "StartDate": "2026-04-01T10:16:30.6339553+07:00",
        "StartDateStr": "sample string 9",
        "EndDate": "2026-04-01T10:16:30.6339553+07:00",
        "EndDateStr": "sample string 11",
        "NewsGroupTypeId": 12,
        "Url": "sample string 13",
        "OnTop": 14,
        "HeaderImageName": "sample string 15",
        "HeaderImageUrl": "sample string 16",
        "CompanyIds": [
          1,
          2
        ],
        "NewsGroupTypeName": "sample string 17",
        "EmployeeCompanyId": 1
      }
    ]
  }
}

text/html

Sample:
{"Code":1,"Errors":["sample string 1","sample string 2"],"Data":{"TotalRows":1,"NewsList":[{"Id":1,"CreatedDate":"2026-04-01T10:16:30.6339553+07:00","CreatedDateStr":"sample string 3","UpdatedDate":"2026-04-01T10:16:30.6339553+07:00","UpdatedDateStr":"sample string 5","Title":"sample string 6","HeaderImageId":1,"Content":"sample string 7","StartDate":"2026-04-01T10:16:30.6339553+07:00","StartDateStr":"sample string 9","EndDate":"2026-04-01T10:16:30.6339553+07:00","EndDateStr":"sample string 11","NewsGroupTypeId":12,"Url":"sample string 13","OnTop":14,"HeaderImageName":"sample string 15","HeaderImageUrl":"sample string 16","CompanyIds":[1,2],"NewsGroupTypeName":"sample string 17","EmployeeCompanyId":1},{"Id":1,"CreatedDate":"2026-04-01T10:16:30.6339553+07:00","CreatedDateStr":"sample string 3","UpdatedDate":"2026-04-01T10:16:30.6339553+07:00","UpdatedDateStr":"sample string 5","Title":"sample string 6","HeaderImageId":1,"Content":"sample string 7","StartDate":"2026-04-01T10:16:30.6339553+07:00","StartDateStr":"sample string 9","EndDate":"2026-04-01T10:16:30.6339553+07:00","EndDateStr":"sample string 11","NewsGroupTypeId":12,"Url":"sample string 13","OnTop":14,"HeaderImageName":"sample string 15","HeaderImageUrl":"sample string 16","CompanyIds":[1,2],"NewsGroupTypeName":"sample string 17","EmployeeCompanyId":1}]}}

application/xml, text/xml

Sample:
<ServiceResultTypedOfNewsSearchResultYj8O1tFc xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/LSW.Common.Models">
  <Code>1</Code>
  <Data xmlns:d2p1="http://schemas.datacontract.org/2004/07/TTMWM_MECLAIM_API.ViewModels">
    <d2p1:NewsList>
      <d2p1:NewsDetail>
        <d2p1:CompanyIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:int>1</d5p1:int>
          <d5p1:int>2</d5p1:int>
        </d2p1:CompanyIds>
        <d2p1:Content>sample string 7</d2p1:Content>
        <d2p1:CreatedDate>2026-04-01T10:16:30.6339553+07:00</d2p1:CreatedDate>
        <d2p1:CreatedDateStr>sample string 3</d2p1:CreatedDateStr>
        <d2p1:EmployeeCompanyId>1</d2p1:EmployeeCompanyId>
        <d2p1:EndDate>2026-04-01T10:16:30.6339553+07:00</d2p1:EndDate>
        <d2p1:EndDateStr>sample string 11</d2p1:EndDateStr>
        <d2p1:HeaderImageId>1</d2p1:HeaderImageId>
        <d2p1:HeaderImageName>sample string 15</d2p1:HeaderImageName>
        <d2p1:HeaderImageUrl>sample string 16</d2p1:HeaderImageUrl>
        <d2p1:Id>1</d2p1:Id>
        <d2p1:NewsGroupTypeId>12</d2p1:NewsGroupTypeId>
        <d2p1:NewsGroupTypeName>sample string 17</d2p1:NewsGroupTypeName>
        <d2p1:OnTop>14</d2p1:OnTop>
        <d2p1:StartDate>2026-04-01T10:16:30.6339553+07:00</d2p1:StartDate>
        <d2p1:StartDateStr>sample string 9</d2p1:StartDateStr>
        <d2p1:Title>sample string 6</d2p1:Title>
        <d2p1:UpdatedDate>2026-04-01T10:16:30.6339553+07:00</d2p1:UpdatedDate>
        <d2p1:UpdatedDateStr>sample string 5</d2p1:UpdatedDateStr>
        <d2p1:Url>sample string 13</d2p1:Url>
      </d2p1:NewsDetail>
      <d2p1:NewsDetail>
        <d2p1:CompanyIds xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:int>1</d5p1:int>
          <d5p1:int>2</d5p1:int>
        </d2p1:CompanyIds>
        <d2p1:Content>sample string 7</d2p1:Content>
        <d2p1:CreatedDate>2026-04-01T10:16:30.6339553+07:00</d2p1:CreatedDate>
        <d2p1:CreatedDateStr>sample string 3</d2p1:CreatedDateStr>
        <d2p1:EmployeeCompanyId>1</d2p1:EmployeeCompanyId>
        <d2p1:EndDate>2026-04-01T10:16:30.6339553+07:00</d2p1:EndDate>
        <d2p1:EndDateStr>sample string 11</d2p1:EndDateStr>
        <d2p1:HeaderImageId>1</d2p1:HeaderImageId>
        <d2p1:HeaderImageName>sample string 15</d2p1:HeaderImageName>
        <d2p1:HeaderImageUrl>sample string 16</d2p1:HeaderImageUrl>
        <d2p1:Id>1</d2p1:Id>
        <d2p1:NewsGroupTypeId>12</d2p1:NewsGroupTypeId>
        <d2p1:NewsGroupTypeName>sample string 17</d2p1:NewsGroupTypeName>
        <d2p1:OnTop>14</d2p1:OnTop>
        <d2p1:StartDate>2026-04-01T10:16:30.6339553+07:00</d2p1:StartDate>
        <d2p1:StartDateStr>sample string 9</d2p1:StartDateStr>
        <d2p1:Title>sample string 6</d2p1:Title>
        <d2p1:UpdatedDate>2026-04-01T10:16:30.6339553+07:00</d2p1:UpdatedDate>
        <d2p1:UpdatedDateStr>sample string 5</d2p1:UpdatedDateStr>
        <d2p1:Url>sample string 13</d2p1:Url>
      </d2p1:NewsDetail>
    </d2p1:NewsList>
    <d2p1:TotalRows>1</d2p1:TotalRows>
  </Data>
  <Errors xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>sample string 1</d2p1:string>
    <d2p1:string>sample string 2</d2p1:string>
  </Errors>
</ServiceResultTypedOfNewsSearchResultYj8O1tFc>