# STEP-5 Creating Plugin and Axios request

1. As an example of using [**Axios**](https://www.npmjs.com/package/axios) we going to display ScandiPWA version at Website Footer\
   For that create **FooterComponent.plugin.js** file in **\[EXTENSION]/src/plugin** folder

{% code title=" scandipwa/packages/@scandipwa/version/src/plugin/FooterComponent.plugin.js" %}

```jsx
import axios from 'axios';

import ContentWrapper from 'Component/ContentWrapper';

export const VERSION_ROUTE = '/scandipwa/version';

const getVersion = (instance) => {
    axios.get(VERSION_ROUTE).then((response) => {
        instance.setState({ version: response.data });
        instance.forceUpdate();
    });
};

const state = (original) => ({
    ...original,
    version: ''
});

const componentDidMount = (args, callback, instance) => {
    callback(...args);
    getVersion(instance);
};

const renderCopyrightContent = (args, callback, instance) => {
    const { version } = instance.state;

    return (
        <>
            { callback(...args) }
            <ContentWrapper
              mix={ { block: 'Footer', elem: 'CopyrightContentWrapper' } }
              wrapperMix={ { block: 'Footer', elem: 'CopyrightContent' } }
              label=""
            >
                <span block="Footer" elem="Copyright">
                    { version }
                </span>
            </ContentWrapper>
        </>
    );
};

export default {
    'Component/Footer/Component': {
        'member-function': {
            componentDidMount,
            renderCopyrightContent
        },
        'member-property': {
            state
        }
    }
};

```

{% endcode %}

![](/files/-MlP-RS-21HAK5MG721d)

**Useful Materials**\
[Axios](https://www.npmjs.com/package/axios) \
[Extension Plugins Templates](https://docs.create-scandipwa-app.com/extensions/application-plugins/templates)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.scandipwa.com/tutorials/accessing-magento-2-controllers/step-5-creating-plugin-and-axios-request.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
