| POST | /customerarticle | Create a new CustomerArticle. | Create a new CustomerArticle directly with price, status, and customer. |
|---|
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| CompanyId | body | Guid? | No | The company id, if empty will use the company id for the user you are logged in with. |
| ArticleId | body | int | Yes | The article id to base this customer article on |
| CustomerId | body | Guid | Yes | The customer id to assign the article to |
| StatusId | body | CustomerArticleStatusEnum? | No | The status of the customer article |
| Price | body | decimal? | No | Optional price override. If not provided, uses the article price. |
| VAT | body | decimal? | No | Optional VAT override. If not provided, uses the article VAT. |
| CurrencyId | body | string | Yes | Optional currency override. If not provided, uses the article currency. |
| Name | Value | |
|---|---|---|
| AwaitingPayment | 1 | |
| AwaitingPaymentFromProvider | 2 | |
| AwaitingPaymentNoTimeLimit | 3 | |
| Active | 4 | |
| Off | 5 |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Id | form | int | No | |
| CompanyId | form | Guid | No | |
| ArticleId | form | int? | No | |
| Price | form | decimal? | No | |
| VAT | form | decimal? | No | |
| CurrencyId | form | string | Yes | |
| StatusId | form | int | No | |
| StatusName | form | string | Yes | |
| CustomerId | form | Guid? | No | |
| CreatedDate | form | DateTime | No | |
| UpdatedDate | form | DateTime | No | |
| Article | form | ArticleResponse | Yes | |
| Customer | form | CustomerArticleCustomerResponse | Yes | |
| Company | form | CustomerArticleCompanyResponse | Yes | |
| PaymentLog | form | List<PaymentLogResponse> | Yes | |
| ResponseStatus | form | ResponseStatus | Yes |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| CompanyId | form | Guid | No | |
| Id | form | int | No | |
| Name | form | string | Yes | |
| ArticleTypeId | form | int | No | |
| Description | form | string | Yes | |
| ImageUrl | form | string | Yes | |
| Active | form | bool | No | |
| Amount | form | int | No | |
| Price | form | double | No | |
| CurrencyId | form | string | Yes | |
| SortOrder | form | int | No | |
| UpdatedDate | form | DateTime | No | |
| CreatedDate | form | DateTime | No | |
| Duration | form | int | No | |
| Services | form | List<ArticleServiceRelation> | Yes | |
| ServiceIds | form | List<int> | Yes | |
| PriceSign | form | string | Yes | |
| VAT | form | decimal? | No | |
| ValidDays | form | int | No | |
| SendNotification | form | bool | No | |
| NotificationEmail | form | string | Yes |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| CompanyId | form | Guid | Yes | |
| Id | form | int | No | |
| ServiceId | form | int | Yes | |
| ArticleId | form | int | Yes |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Id | form | Guid | No | |
| Firstname | form | string | Yes | |
| Lastname | form | string | Yes | |
| form | string | Yes | ||
| Phone | form | string | Yes |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Id | form | Guid | No | |
| Name | form | string | Yes | |
| LogoType | form | string | Yes | |
| form | string | Yes | ||
| Phone | form | string | Yes | |
| City | form | string | Yes | |
| Street1 | form | string | Yes | |
| ZipCode | form | string | Yes | |
| CountryId | form | string | Yes |
| Name | Parameter | Data Type | Required | Description |
|---|---|---|---|---|
| Id | form | int | No | |
| Amount | form | double? | No | |
| AmountCredited | form | double? | No | |
| CurrencyId | form | string | Yes | |
| Comments | form | string | Yes | |
| Created | form | DateTime | No | |
| Updated | form | DateTime | No |
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /customerarticle HTTP/1.1
Host: api.bokamera.se
Accept: application/json
Content-Type: application/json
Content-Length: length
{"CompanyId":"00000000-0000-0000-0000-000000000000","ArticleId":0,"StatusId":"0","Price":0,"VAT":0,"CurrencyId":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"Id":0,"ArticleId":0,"Price":0,"VAT":0,"CurrencyId":"String","StatusId":0,"StatusName":"String","CustomerId":"00000000-0000-0000-0000-000000000000","Article":{"Id":0,"Name":"String","ArticleTypeId":0,"Description":"String","ImageUrl":"String","Active":false,"Amount":0,"Price":0,"CurrencyId":"String","SortOrder":0,"Duration":0,"Services":[{"Id":0,"ServiceId":0,"ArticleId":0}],"ServiceIds":[0],"PriceSign":"String","VAT":0,"ValidDays":0,"SendNotification":false,"NotificationEmail":"String"},"Customer":{"Firstname":"String","Lastname":"String","Email":"String","Phone":"String"},"Company":{"Name":"String","LogoType":"String","Email":"String","Phone":"String","City":"String","Street1":"String","ZipCode":"String","CountryId":"String"},"PaymentLog":[{"Id":0,"Amount":0,"AmountCredited":0,"CurrencyId":"String","Comments":"String"}],"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}}}