# Company next activity date format

**URL:** <https://community.hubspot.com/t/company-next-activity-date-format/87692>\
**Category:** APIs & Integrations\
**Tags:** companies\
**Created:** [August 17, 2023, 8:26am UTC](https://community.hubspot.com/t/company-next-activity-date-format/87692 "2023-08-17T08:26:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Arunesh](https://avatars.discourse-cdn.com/v4/letter/a/e9a140/32.png) [@Arunesh](https://community.hubspot.com/u/Arunesh)\
**Post date:** [August 17, 2023, 8:26am UTC](https://community.hubspot.com/t/company-next-activity-date-format/87692/1 "2023-08-17T08:26:51Z")

</div>

Hi,  
I got the company next activity date from API. I thought the data type is datetime or date, but i got empty string for few. Is it expected? Can we get null istead of “” this empty string.  
Thanks in advance

---

<div class="post-metadata">

**Author:** ![coldrickjack](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/coldrickjack/32/6684_2.png) [@coldrickjack](https://community.hubspot.com/u/coldrickjack)\
**Post date:** [August 17, 2023, 10:20am UTC](https://community.hubspot.com/t/company-next-activity-date-format/87692/2 "2023-08-17T10:20:47Z")

</div>

Hey @Arunesh,

I’m unable to replicate what you are seeing. For instance when I retreive a particular company from the CRM using [GET /crm/v3/objects/company/{companyId}](https://developers.hubspot.com/docs/api/crm/companies) a null value is returned for the “Next Activity Date” property. See my request below:

```lia-code-sample
GET https://api.hubapi.com/crm/v3/objects/company/8200747722?properties=notes_next_activity_date
RESPONSE
{
 "id": "8200747722",
 "properties": {
 "createdate": "2023-08-07T08:12:56.043Z",
 "hs_lastmodifieddate": "2023-08-16T14:33:56.468Z",
 "hs_object_id": "8200747722",
 "notes_next_activity_date": null
 },
 "createdAt": "2023-08-07T08:12:56.043Z",
 "updatedAt": "2023-08-16T14:33:56.468Z",
 "archived": false
}

```

I am retrieveing “notes\_next\_activity\_date” which is defined as “Date of the next upcoming scheduled sales activity for this company record.”. See below:

```lia-code-sample
"name": "notes_next_activity_date",
"label": "Next Activity Date",
"type": "datetime",
"fieldType": "date",
"description": "Date of the next upcoming scheduled sales activity for this company record.",
"groupName": "company_activity"

```

In the UI when I check the company I see this:

 ![Screenshot 2023-08-17 at 11.19.26.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/0/7/07cccc8f07ee847b7807e3d8f15c3ed98c596263.png)

Questions for you:

- Are you using the endpoint above?
- Which property are you trying to retrieve - is it the “notes\_next\_activity\_date” property?
- Can you share any more information about your request

---

<div class="post-metadata">

**Author:** ![Arunesh](https://avatars.discourse-cdn.com/v4/letter/a/e9a140/32.png) [@Arunesh](https://community.hubspot.com/u/Arunesh)\
**Post date:** [August 18, 2023, 4:49pm UTC](https://community.hubspot.com/t/company-next-activity-date-format/87692/3 "2023-08-18T16:49:32Z")

</div>

Hi @jackcoldrick  
I got the empty string when the activity was deleted. Say I create an activity for an upcoming follow up and delete that. While retrieving the data for next activity I get the empty string

 ![Arunesh_0-1692377577856.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/8/e/8ee13d36712a896e0eaaa551f5ceb841f7d266e4.png)

---

<div class="post-metadata">

**Author:** ![coldrickjack](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/coldrickjack/32/6684_2.png) [@coldrickjack](https://community.hubspot.com/u/coldrickjack)\
**Post date:** [August 18, 2023, 5:23pm UTC](https://community.hubspot.com/t/company-next-activity-date-format/87692/4 "2023-08-18T17:23:01Z")

</div>

Hey @Arunesh

I understand, I am seeing the same. See below:

**1) Without activity created**

I can see “_notes\_next\_activity\_date_” is null.

```lia-code-sample
GET https://api.hubapi.com/crm/v3/objects/company/8200747722?properties=notes_next_activity_date
{
 "id": "8200747722",
 "properties": {
 "createdate": "2023-08-07T08:12:56.043Z",
 "hs_lastmodifieddate": "2023-08-16T14:33:56.468Z",
 "hs_object_id": "8200747722",
 "notes_next_activity_date": null
 },
 "createdAt": "2023-08-07T08:12:56.043Z",
 "updatedAt": "2023-08-16T14:33:56.468Z",
 "archived": false
}

```

**2) When activity created**

I see “_notes\_next\_activity\_date_” has timestamp.

```lia-code-sample
GET https://api.hubapi.com/crm/v3/objects/company/8200747722?properties=notes_next_activity_date
{
 "id": "8200747722",
 "properties": {
 "createdate": "2023-08-07T08:12:56.043Z",
 "hs_lastmodifieddate": "2023-08-18T17:18:30.546Z",
 "hs_object_id": "8200747722",
 "notes_next_activity_date": "2023-08-23T07:00:00Z"
 },
 "createdAt": "2023-08-07T08:12:56.043Z",
 "updatedAt": "2023-08-18T17:18:30.546Z",
 "archived": false
}

```

**3) When activity deleted**

I see “_notes\_next\_activity\_date_” is an empty string.

```lia-code-sample
GET https://api.hubapi.com/crm/v3/objects/company/8200747722?properties=notes_next_activity_date
{
 "id": "8200747722",
 "properties": {
 "createdate": "2023-08-07T08:12:56.043Z",
 "hs_lastmodifieddate": "2023-08-18T17:19:20.295Z",
 "hs_object_id": "8200747722",
 "notes_next_activity_date": ""
 },
 "createdAt": "2023-08-07T08:12:56.043Z",
 "updatedAt": "2023-08-18T17:19:20.295Z",
 "archived": false
}

```

I do still think this is working as designed and I’d just recommend checking the response for the presence of a falsy value i.e something that will evaluate to false (undefined, null, NaN, 0, “”).
