> ## Documentation Index
> Fetch the complete documentation index at: https://docs.megaport.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Viewing Activity Logs

> This help topic describes the Megaport Portal activity logs and how to view activity logs for your Megaport Portal account.

export const Image = ({src, alt = '', caption, width, height, shadow}) => {
  const errorPrefix = '\x1b[31;1;4mERROR\x1b[0m: Image -';
  if (typeof src !== 'string') {
    src = String(src);
  }
  if (!src || src === 'undefined') {
    console.error(`${errorPrefix} \`src\` is required — rendering an empty string instead`);
    return <></>;
  }
  const img = <img className={['mega-image-style', shadow ? 'shadow' : ''].join(' ')} src={src} alt={alt} width={width} height={height} style={{
    display: 'block'
  }} />;
  return caption ? <figure>
      {img}
      <figcaption style={{
    textAlign: 'center',
    width
  }}>{caption}</figcaption>
    </figure> : img;
};

The Activity Log options on the Settings menu allow you to view activities that users have performed. The **User Activity** option shows activities only for the logged-in user, while the **Company Activity** option shows the activities of all users in the current company.

Users with any Portal role can view the **User Activity** option, however, only Company Admins can view the **Company Activity** option. For more information, see [Managing User Roles](/partners/account/profiles).

The Activity Logs record all activities that occur, and include the date and time of each event. Activity logs can provide an audit trail to prove any malicious activity via compromised accounts, show evidence of activities performed by API keys, and can be useful when troubleshooting a system issue.

<Note>
  Activity Log events are retained for 6 months.
</Note>

## What information is logged

The system logs these activities:

* Logging in to the Portal (successful and failed)
* Logging in to the Portal with Single Sign-On
* Logging out of the Portal
* Enabling, resetting, and disabling Multi-Factor Authentication (MFA) for a user
* Configuring, deploying, and updating services (successful or failed)
* Requesting approval for creating, changing, and terminating services
* Withdrawing requests for creating, changing, and terminating services
* Approval or rejection of requests to create, change, and terminate services
* Approving, denying, or canceling a speed change
* Approving or denying connections
* Updating Port terms
* Terminating services
* Registering payment cards, updating and removing cards, and making payments
* Setting up and updating service keys
* Creating, updating, and deleting webhook endpoints
* Updating user profiles
* Creating a company profile or Megaport Marketplace profile
* Setting up and updating custom branding
* Setting up and updating billing markets
* Saving and managing configurations
* Updating user notification settings
* Managing users
* Locking and unlocking services
* Encountering issues with the ordering process
* Creating and updating a managed account
* Creating and updating Prefix Filter and Packet Filter lists
* API calls from external sources (such as customer integrations)
* Whether the activity is created by an API key user
* The client ID of the API key if the activity was created by an API key user
* The type of service for which the activity log is being created
* The UID of the service for which the activity log is being created

## What information isn’t logged

The Activity Log does not provide usage or billing information for a Megaport service, such as performance for a VXC or IX, or how much it costs. For more information about VXC billing, see [VXC Pricing and Contract Terms](https://docs.megaport.com/finance/vxc-pricing/).

## What logs can users view

The following table shows the access and functionality available in the **User Activity** and **Company Activity** pages, based on user role.

| **User Role**                                   | **Activity Log Functionality**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| ----------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Non Admin (All role types except Company Admin) | **User Activity**<br />Can view their own activities.<br />Can filter activities by:<br /><ul><li>Activity name</li><li>Date</li></ul>                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| Company Admin                                   | **User Activity**<br />Can view their own activities.<br />Can filter activities by:<br /><ul><li>Activity name</li><li>Date</li></ul><br />**Company Activity**<br />Can view:<br /><ul><li>Activities of all users in the company</li><li>Activities of all API keys associated with the company. The User column displays the API key name.</li><li>Activities created by Megaport staff, for example, when performing support investigations</li><li>All system-generated activities</li></ul><br />Can filter activities by:<br /><ul><li>Date</li><li>User type</li><li>User</li><li>Activity name</li></ul> |

## Viewing activity logs

Depending on your role, you can perform the following actions to locate and view specific activity logs:

* **Sort** -- All users can sort activity logs by date/time.
* **Filter** -- All users can filter activity logs by date and activity name. Company Admins can also filter activity logs by user type or specific user.
* **Search** -- Company Admins can use a free text search on the Company Activity page to locate specific activity logs. The search matches all log details, including user names, activity names, and full descriptions in the **More Details** option.

**To view the activity log table**

1. Log in to a partner account.

2. Choose:

   * **User Menu > User Settings > User Activity** -- to view your own activities,  or
   * **User Menu > Admin Settings > Company Activity** -- to view company-wide activities.

     <Image src="/images/partners/account/user-menu-settings.png" alt="Portal User Menu Settings option" shadow={true} width={300} />

   The Activity Log page appears, showing activities by date, user type and user name (Company Activity only), and activity name.

   <Image src="/images/portal-admin/activity-event-log.png" alt="Activity Event Log" shadow={true} width={850} />

3. Click **More Details** to view additional information about an activity, including an expanded description to further explain the action that triggered the log entry.

**To sort activities**

You can sort activity logs by date and time, in either ascending or descending order.

* In the Activity Log page, click the small up/down triangle next to the **Date** column heading.
  <Image src="/images/portal-admin/activity-date-filter.png" alt="Portal User Menu Settings option" shadow={true} width={350} />
  The activity log table reloads.
* Click the up/down triangle again to reverse the sort order.\
  The up or down triangle next to the **Date** column heading indicates the current bidirectional sort order.

**To filter activities**

You can filter all activity logs by date and activity name. You can also filter Company Activity logs by user type and user.

1. In the Activity Log page, click the filter icon next to the column heading on which you want to filter.\
   You can filter on activity date, user type, user, and activity name.
   <Image src="/images/portal-admin/activity-filter-columns.png" alt="Activity Event Log" shadow={true} width={750} />

2. Filter the activity log table:
   * **To filter by date** -- Select a single date or select two dates to filter between the date range.
   * **To filter by user type** – Select a user type from the list.
   * **To filter by user** -- Search for and select a user name.
   * **To filter by activity name** -- Search for and select an activity name.

3. Click **Apply**.\
   The filter is added to the top of the activity log table. You can save one filter per column at a time. Any saved filters are not retained if you leave the activity page and then return to the page.
   <Image src="/images/portal-admin/activity-filter-saved.png" alt="Activity Event Log" shadow={true} width={750} />

**To search for activities**

Company Admins can use a free text search on the Company Activity page to locate specific activity logs. The search matches all log details, including user names, activity names, and full descriptions in the **More Details** option. Any partial or complete matches are included in the search results.

1. Choose User Menu > Admin Settings > Company Activity.
2. In the Company Activity page, enter the search text in the **Search** field on the right.  For example, enter **IDP** to search for any SSO sign up or login activities.\
   Activity logs matching your search update in real-time as you type.
   <Image src="/images/portal-admin/activity-search.png" alt="Activity Event Log" shadow={true} width={750} />
3. Use the sort, filter, and pagination controls to refine the search results and locate specific activity log entries.

## Helpful references

* [Managing User Roles](/partners/account/profiles)
